Linux está inspirado en el sistema operativo Unix, que apareció por primera vez en 1969, y que ha sido constantemente utilizado y desarrollado desde entonces. Muchas de las convenciones de diseño que hay detrás de Unix también están en Linux y son fundamentales para entender los aspectos básicos del sistema.
Unix estuvo orientado inicialmente a la interfaz de línea de órdenes, y ese legado ha llegado hasta Linux. Por tanto, la interfaz gráfica de usuario con sus ventanas, iconos y menús se crea sobre una interfaz básica de línea de órdenes. Además, ésto significa que el sistema de archivos de Linux está estructurado para ser fácilmente manipulable y accesible desde la línea de órdenes.
Los sistemas de archivos en Linux y Unix se organizan en una estructura jerárquica arborescente. El nivel más alto del sistema de archivos es el
Por ejemplo, /home/jebediah/cheeses.odt
muestra la ruta completa hacía el archivo cheeses.odt
del subdirectorio jebediah
que está en el directorio home
, que a su vez está en el directorio raíz (/
).
Dentro del directorio raíz (/
) hay un conjunto de importantes directorios del sistema, que son comunmente usados entre diversas distribuciones de Linux. A continuación se puede ver una lista de directorios comunes que se encuentran debajo del directorio raíz (/
):
/bin
- Aplicaciones binarias importantes.
/boot
- Archivos de configuración de arranque (boot)
/dev
- los archivos de dispositivos (devices)
/etc
- archivos de configuración, scripts de inicio, etc...
/home
- directorios personales - home - de los usuarios locales
/lib
- librerias del sistema
/lost+found
- proporciona un sistema de "perdido+encontrado" (lost+found) para los archivos que existen bajo el directorio raíz (/
)
/media
- medios extraíbles montados (cargados) como CDs, cámaras digitales, etc...
/mnt
- sistemas de archivos montados
/opt
- proporciona una ubucación en la que se pueden instalar aplicaciones optativas
/proc
- directorio dinámico especial que mantiene información sobre el estado del sistema, incluyendo los procesos actualmente en ejecución
/root
- directorio personal del usuario root
/sbin
- binarios importantes del sistema
/sys
- archivos del sistema (system)
/tmp
- archivos temporales
/usr
- aplicaciones y archivos a los que puede acceder la mayoría de los usuarios
/var
- archivos variables como archivos de registros y bases de datos
En un sistema Linux, los archivos tienen permisos que permiten/impiden verlos, modificarlos y/o ejecutarlos. El superusuario (root) tiene la capacidad de acceder a cualquier archivo del sistema. Cada archivo tiene sus propias restricciones de acceso, restricciones de usuario y está asociado a un propietario/grupo.
Cada archivo tiene tres grupos de permisos, que por orden de importancia, son estos:
usuario
se aplica al usuario al que pertenece el archivo
grupo
se aplica al grupo al que está asociado el archivo
otros
se aplica a todos los demás usuarios
Dentro de cada uno de los tres grupos de permisos, se encuentran los permisos en sí. Éstos, así como la forma en la que se aplican a archivos y directorios, se detallan a continuación:
lectura
los archivos se pueden ver/abrir
se puede ver el conteido del directorio
escritura
los archivos se pueden cambiar o borrar
se puede modificar el contenido del directorio
ejecutar
executable files can be run as a program
los directrorios permiten situarse dentro
Para very editar los permisos de ficheros y directorios, abra y pulse el botón derecho sobre un archivo o directorio. Luego escoja -> -> . Los permisos se muestraan en la pestaña Permisos y puede modificarlos si es el propietario del archivo/directorio.
Para saber más acerca de los permisos en Linux, consulte la página de permisos de ficheros en la Wiki de Ubuntu.
Working at the command line is not as daunting a task as you would think. There is no special knowledge needed to know how to use the command line, it is a program like everything else. Most things in Linux can be done using the command line, although there are graphical tools for most programs, sometimes they are just not enough. This is where the command line comes in handy.
The Terminal is located in -> . The terminal is often called the command prompt or the shell. In days gone by, this was the way the user interacted with the computer, however Linux users have found that the use of the shell can be quicker than a graphical method and still holds some merit today. Here you will learn how to use the terminal.
The original use of the terminal was a file browser and indeed it is still used as a file browser, in the event of the graphical environment failing. You can use the terminal as a file browser to navigate your files and undo the changes that have been made.
La orden ls (LiSta) muestra los archivos diferenciados por colores y texto con formato
La orden mkdir (del inglés MaKeDIRectory) crea un directorio.
La orden cd (CambiarDirectorio) hará que Ud. pase del directorio actual a cualquier otro directorio que especifique.
La orden cp (CoPiar) copia los archivos que usted especifique. La orden cp -r copia cualquier directorio.
La orden rm borra el archivo especificado por su nombre. La orden rm -rf borra el directorio especificado.
La orden mv (MoVer) renombra/mueve ael fichero o directorio que se le indique.
The locate command will search your computer for any filename you specify. It uses an index of the files on your system to work quickly: to update this index run the command updatedb. This command is run automatically each day, if you leave your computer on. It needs to be run with administrative privileges (see “Root y sudo”).
You can also use wildcards to match one or more files, such as "*" (for all files) or "?" (to match one character).
For a more thorough introduction to the Linux command line, please read the command line introduction on the Ubuntu wiki.
All of the configurations and settings in Linux are saved in text files. Even though you most often can edit configurations through the graphical interface, you may occasionally have to edit them by hand. Mousepad is the default Xubuntu text editor, which you can launch by clicking -> -> on the desktop menu system.
At times in this guide, Mousepad is run from the command line using gksudo, which runs Mousepad with administrative privileges, in order to modify configuration files.
If you need to use a text editor from the command line, you can use nano, which is a simple to use text editor. When running it from the command line, always use the following command, which ensures that the editor will not introduce line breaks:
nano -w
Para más información acerca de cómo usar nano, consulte la guía en la wiki.
There are also quite a few other terminal-based editors available in Ubuntu, popular ones include VIM and Emacs (the pros and cons of each are cause for much friendly debate within the Linux community). These are often more complex to use than nano, but are also more powerful.
The root user in GNU/Linux is the user which has administrative access to your system. Normal users do not have this access for security reasons. However, Ubuntu does not include the root user. Instead, administrative access is given to individual users, who may use the "sudo" application to perform administrative tasks. The first user account you created on your system during installation will, by default, have access to sudo. You can restrict and enable sudo access to users with the Users and Groups application (see “Managing Users and Groups” for more information).
When you run an application that requires root privileges, sudo will ask you to input your normal user password. This ensures that rogue applications cannot damage your system, and serves as a reminder that you are about to perform administrative actions which require you to be careful!
To use sudo when using the command line, simply type "sudo" before the command you wish to run. Sudo will then prompt you for your password.
Sudo will remember your password for a set amount of time. This feature was designed to allow users to perform multiple administrative tasks without being asked for a password each time.
![]() |
|
Be careful when doing administrative tasks, you might damage your system! |
Some other tips to using sudo include:
To use a "root" terminal, type "sudo -i" at the command line.
The entire group of default graphical configuration tools in Ubuntu already use sudo, so they will prompt you for your password if needed.
When starting graphical tools with "sudo", run it with "gksudo" instead. This will open a small graphical window that prompts the user for his password. "gksudo" is convenient if you want to set up a launcher for Synaptic on your panel, or something similar, where you would normaly not have the possiblity to enter your password.
For more information on the sudo program and the absence of a root user in Ubuntu, read the sudo page on the Ubuntu wiki.
An incredible amount of information about Linux is available on the Internet. To get started, I recommend the excellent and comprehensive tutorial Getting Started with Linux.
For people who already know the basics, the tutorial Intermediate Level User Linux Course is a good read.