Accessing a command line with the Terminal Activity
Use the Terminal Activity to gain access to a Linux command prompt. Linux is the underlying operating system that tells the computer hardware commands.
When you first start the Terminal Activity, you see a command prompt that ends in a $. This sign indicates that you are logged in as the olpc user. To log in as root, type the following (with a minus sign):
su -
If you log in as root, your command prompt changes to end in a # sign. You can run more commands as the root user than as the olpc user so only change to root for the commands that require root. By default, root does not have a password assigned to it, so you can type su - at the command prompt to log in as root.
To set passwords
If you want to set the password for the root user, type the following at the command prompt:
passwd
Or, to change the password for the olpc user while loggd on as root, type the following and then follow the instructions on screen:
passwd olpc
Changing password for user ....
New UNIX password:
Retype new UNIX password:
passwd: all authentication tokens updated successfully.
To determine the IP address for your XO
- Make sure you are connected to the Internet by going to the Neighborhood View.
- Launch the Terminal Activity.
- If you are using wireless Internet access, type the following:
iwconfig
-
In the line next to inetaddr: , look for the IP address for your laptop, such as 192.168.0.2.
To transfer files to and from your XO laptop wirelessly
- To upload the file test.py from a pc to the xo (into /home/olpc), use: scp FILE_NAME USER@IP:TO_DIRECTORY
scp test.py olpc@192.168.0.2:/home/olpc
- To download the file /home/olpc/xo_test.py from the xo to a local pc, simply reverse the arguments:
scp olpc@192.168.0.2:/home/olpc/xo_test.py ./
Some additional common commands include the following:
What am I learning?
You are learning how a computer works in layers with a graphical user interface running on top of a text-based command layer.
Why is this important?
You can give a computer text instructions to manipulate files and do countless additional tasks.