beginning Linux guide

This was taken from an email I sent to Jem and Trinity about beginning in Ubuntu Linux. It might also be useful to see my dated Beginning Linux Commands guide. Any questions about something I do or don’t have on here, as well as your own Linux tips, can be posted as comments.

Note: Don’t look on this guide as though you have to learn all this stuff right now in order to be able to use Linux. No. You can get around otherwise, enjoying Linux and getting work done at the same time without messing around with the command-line, which is what a lot of this guide deals with. Look over this guide and then pick and choose what you need. Want to learn how to change file permissions? Check out the section on the chmod command. Want to know what program to use for a certain task? Check out that section. You don’t have to memorize all this stuff to get around, but it’s there if you need it.

Useful Links

Command-Line Interface Beginning Commands

The table was a little wide so I put it in its own separate file.

Debian (or Debian derivative) Commands

  • apt-cache search SOMETHING – Search the Debian archives for SOMETHING.
  • apt-cache show PACKAGE – Show info about PACKAGE, such as its name, size, description, dependencies, etc.
  • apt-get install PACKAGE – Install all the dependencies for PACKAGE and PACKAGE itself.
  • apt-get update – Run before dist-upgrade-ing.
  • apt-get dist-upgrade – Upgrade all out-of-date programs on the system.

Installing TrueType Fonts

  • Copy your new font(s) into /usr/share/fonts/truetype
  • Run ttmkfdir
  • Restart Gimp (or whichever program you wish to use them in.)

Chmod Tutorial

U G O
rwx rwx rwx
421 421 421
read = 4 U = user
write = 2 G = group
execute = 1 O = other

-rwxrwxrwx
-rw-rw-rw-
-rwxr–r–
etc.

You add up the permissions you want and stick them in the slot you want. If you want the user to be able to read and write to a file, that’s 4 (read) + 2 (write) = 6 (e.g. chmod 644 harry.html). This was the way I learned, but there’s also a simpler way. person+permission to add a permission (e.g. chmod g+x jim.sh) or person-permission to remove a permission (e.g. chmod o-w yellow.txt).

Programs I Recommend for a Given Task

  • Music player – amaroK
  • Browser – Firefox
  • HTML editor – vim or Bluefish
  • Graphics editor – The GIMP
  • Office suite – OpenOffice
  • Mail – Thunderbird
  • Instant messenger – gaim (supports AIM, Yahoo!, ICQ, Jabber, etc.)
  • CD ripper – Sound Juicer, grip, or ripperx
  • Card game – Pysol (has freakin’ tons of different card games)
  • Window manager – IceWM
  • File browser – Krusader (Gnome probably has an equivalent) or mc (without a GUI but very powerful–type from a command-line)

General Tips

  • Always try to apt-get a program before installing from source. It keeps your system cleaner and everything more interconnected, making it easier to maintain and update.
  • The man command is your buddy.
  • If you’re having a problem (e.g. your music player won’t play any sounds), chances are someone else has had the same problem before. Google a description of your problem; if it’s a lack of configuration for something, you’ll probably find a HOWTO describing how to get things set up (e.g. The Linux Sound Playing HOWTO).
  • Get used to the command-line. Being able to work with just a GUI leaves you out of a lot of the beauty of Linux (and Macs). If you’re comfortable with both the GUI and the CLI parts of an operating system, you’ll be a lot more versatile, of course, (so if your X server won’t start and all you have is a console, you can still get around, edit some config files, and get stuff working again) and you’ll be able to do things faster because GUI’s may be pretty, but they aren’t always the shortest route to accomplish a task.
  • Vim is faaaaabulous. It’s a text editor that’s insanely powerful because it’s got a ton of commands. There’s a steep learning curve but it’s worth it.

Webserver Stuff

Problem: /var/www is by default accessible by root only, but you want to stick your web page stuff there to be able to access it at http://localhost

Solution: You don’t even have to mess with /var/www; in your home directory (cd ~ or cd or cd /home/USER will get you there), make a directory called public_html if you don’t already have one. You can put your web stuff in there and then access it at http://localhost/~USER

This entry was posted in Linux | Current music Rammstein - Feuer und Wasser. Bookmark the permalink. Post a comment or leave a trackback: Trackback URL.

3 Comments

  1. Posted 21 December 2005 at 2:23 PM | Permalink

    I would just like you to know that my username is not “melissa” on my system :D

    And I’m sorry, but “man less” just cracks me up! Ha!

    This has absolutely no real relevance to this post so I will shut up now!

  2. Posted 27 June 2006 at 10:18 AM | Permalink

    Ok, so I’m trying to get back into Linux because I need the experience.. following your advise from before, I started putting files in /home/USER/public_html and was getting the following error:

    Warning: Unknown(/home/jem/public_html/index.php): failed to open stream: Permission denied in Unknown on line 0

    Warning: (null)(): Failed opening ‘/home/jem/public_html/index.php’ for inclusion (include_path=’.:/usr/share/php:/usr/share/pear’) in Unknown on line 0

    I assumed it was a permissions error, so I changed the permissions to 644 – which is what I’d usually use online.. still get the same error. However, I created a public_html folder in /var/www/ and a test index.php, and after changing the permissions to 644, it works fine. So, should I stick with using /var/www/public_html/ ..or is there a way to sort out the error above? Also, how can I make it so that a file is automatically given permissions of 644 when created in that folder?

    Please bear with my ignorance.. and if you don’t have time to answer me – no worries.

  3. Posted 27 June 2006 at 12:00 PM | Permalink

    Try opening your /etc/php.ini file and checking the ‘Paths and Directories’ section. There’s a bit that says

    ; The directory under which PHP opens the script using /~username used only
    ; if nonempty.
    user_dir =

    I would set user_dir equal to public_html

Post a Comment

Your email is never published nor shared. Required fields are marked *

*
*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>