<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://ccl2it-formation.in2p3.fr/index.php?action=history&amp;feed=atom&amp;title=Tutorial_%E2%80%94_Basic_usage_of_CC-IN2P3</id>
	<title>Tutorial — Basic usage of CC-IN2P3 - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://ccl2it-formation.in2p3.fr/index.php?action=history&amp;feed=atom&amp;title=Tutorial_%E2%80%94_Basic_usage_of_CC-IN2P3"/>
	<link rel="alternate" type="text/html" href="https://ccl2it-formation.in2p3.fr/index.php?title=Tutorial_%E2%80%94_Basic_usage_of_CC-IN2P3&amp;action=history"/>
	<updated>2026-05-26T20:06:14Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.45.3</generator>
	<entry>
		<id>https://ccl2it-formation.in2p3.fr/index.php?title=Tutorial_%E2%80%94_Basic_usage_of_CC-IN2P3&amp;diff=49&amp;oldid=prev</id>
		<title>Gscamps: Created page with &quot;{{Contribute}}  == Tutorial — Basic usage of CC-IN2P3 ==  === Introduction ===  This tutorial is part of a collaborative wiki: feel free to update it, modify it, or add relevant information for future users.  === Connecting to the computing center ===  From a local terminal on your computer, you can connect to the CC-IN2P3 server using SSH:  &lt;pre&gt; ssh &lt;USERNAME&gt;@cca.in2p3.fr &lt;/pre&gt;  After entering your username and password, if the connection is successful you should s...&quot;</title>
		<link rel="alternate" type="text/html" href="https://ccl2it-formation.in2p3.fr/index.php?title=Tutorial_%E2%80%94_Basic_usage_of_CC-IN2P3&amp;diff=49&amp;oldid=prev"/>
		<updated>2026-05-03T12:05:39Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;{{Contribute}}  == Tutorial — Basic usage of CC-IN2P3 ==  === Introduction ===  This tutorial is part of a collaborative wiki: feel free to update it, modify it, or add relevant information for future users.  === Connecting to the computing center ===  From a local terminal on your computer, you can connect to the CC-IN2P3 server using SSH:  &amp;lt;pre&amp;gt; ssh &amp;lt;USERNAME&amp;gt;@cca.in2p3.fr &amp;lt;/pre&amp;gt;  After entering your username and password, if the connection is successful you should s...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{{Contribute}}&lt;br /&gt;
&lt;br /&gt;
== Tutorial — Basic usage of CC-IN2P3 ==&lt;br /&gt;
&lt;br /&gt;
=== Introduction ===&lt;br /&gt;
&lt;br /&gt;
This tutorial is part of a collaborative wiki: feel free to update it, modify it, or add relevant information for future users.&lt;br /&gt;
&lt;br /&gt;
=== Connecting to the computing center ===&lt;br /&gt;
&lt;br /&gt;
From a local terminal on your computer, you can connect to the CC-IN2P3 server using SSH:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ssh &amp;lt;USERNAME&amp;gt;@cca.in2p3.fr&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
After entering your username and password, if the connection is successful you should see a message similar to:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
################################################################################&lt;br /&gt;
               _________________________________________________&lt;br /&gt;
              |                                                 |&lt;br /&gt;
              | Bienvenue au Centre de Calcul de l&amp;#039;IN2P3 / CNRS |&lt;br /&gt;
              |_________________________________________________|&lt;br /&gt;
&lt;br /&gt;
Pour votre utilisation quotidienne des serveurs interactifs,&lt;br /&gt;
merci de consulter le guide des bonnes pratiques :&lt;br /&gt;
https://doc.cc.in2p3.fr/fr/Daily-usage/access/cca-connect.html#cca-best-practices&lt;br /&gt;
&lt;br /&gt;
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~&lt;br /&gt;
                ______________________________________________&lt;br /&gt;
               |                                              |&lt;br /&gt;
               | Welcome to the IN2P3 Computing Center / CNRS |&lt;br /&gt;
               |______________________________________________|&lt;br /&gt;
&lt;br /&gt;
For your daily use of interactive servers, please read the best practices guide:&lt;br /&gt;
https://doc.cc.in2p3.fr/en/Daily-usage/access/cca-connect.html#cca-best-practices&lt;br /&gt;
&lt;br /&gt;
################################################################################&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You now have access to a terminal on the computing center in Lyon.&lt;br /&gt;
&lt;br /&gt;
=== Preparing a job ===&lt;br /&gt;
&lt;br /&gt;
Create a new directory and move into it:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mkdir test_hello_world&lt;br /&gt;
cd test_hello_world&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Copy an example C program:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /pbs/throng/l2it/tutoriel_exemple_file/hello_world_c/hello_world.c ./&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can inspect the file with:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cat hello_world.c&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Compile the code to create an executable:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gcc hello_world.c -o hello_world&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Submitting a job ===&lt;br /&gt;
&lt;br /&gt;
Copy a job script:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cp /pbs/throng/l2it/tutoriel_exemple_file/hello_world_c/job.sh ./&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inspect it with:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cat job.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Lines starting with #SBATCH provide instructions to the scheduler (job name, time limit, memory, etc.).  &lt;br /&gt;
The command:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./hello_world &amp;gt; hello_world.out&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
runs the program and saves the output.&lt;br /&gt;
&lt;br /&gt;
Submit the job:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sbatch job.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You should see output similar to:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Submitted batch job XXXXXXXX&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Check the job status:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
squeue&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If the job no longer appears, it has completed.&lt;br /&gt;
&lt;br /&gt;
View output files:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cat test_XXXX.log&lt;br /&gt;
cat hello_world.out&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Expected result:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Hello, World!&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Cancelling a job ===&lt;br /&gt;
&lt;br /&gt;
To cancel a job:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
scancel &amp;lt;JOB_ID&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Find the job ID with:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
squeue&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Downloading data locally ===&lt;br /&gt;
&lt;br /&gt;
To copy files from the computing center to your local machine:&lt;br /&gt;
&lt;br /&gt;
1. Exit the remote session:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
exit&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Use scp from your local terminal:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
scp &amp;lt;USERNAME&amp;gt;@cca.in2p3.fr:test_hello_world/hello_world.out ./&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The file will be copied to your current directory.&lt;br /&gt;
&lt;br /&gt;
=== Further resources ===&lt;br /&gt;
&lt;br /&gt;
* https://doc.cc.in2p3.fr/index.html&lt;/div&gt;</summary>
		<author><name>Gscamps</name></author>
	</entry>
</feed>