Bookmark Topic Watch Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin
  • Likes 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
This page is the FAQ for the JavaRanch Linux/Unix forum. It's editable by everyone, so add your own content as you see fit.


  • What is Unix?
  • What is Linux?
  • What is a Linux Distribution?
  • How do I install Linux?
  • What is The Best Linux Distribution?
  • How do I learn Linux?
  • How do I install Java?
  • What is the cause of the 'Can't connect to X11 window server' message?
  • What makes Free Software 'Free'?
  • Links to other useful information




  •  
    What is Unix?

    Unix is a computer operating system developed in the 1960's and 70's by Bell Labs (AT+T). The trademark is currently owned by The Open Group. You can find out more about Unix here. Popular Unix-like operating systems include IBM AIX, BSD, HP-UX, Linux, Solaris and Mac OS X



     
    What is Linux?

    Linux is a Unix-like operating system kernel created by Linus Torvalds, who owns the trademark on the name "Linux" and oversees development of the kernel. The kernel is bundled with other software to create what is called a "Linux distribution".



     
    What is a Linux Distribution?

    A Linux distribution is the Linux kernel packaged with other system and application software to make a full-featured operating system. Some Linux distributions are small and fill a very specific niche, such as the Smoothwall firewall. Others are general-purpose operating systems with office and software development tools, for example, the currently very popular Ubuntu distribution.

    The differences between Linux distributions are usually rooted in the philosophy of the company, team or individual that created the distribution. Some distributions, like Ubuntu are intended for general-purpose desktops as well as ease-of-use. Fedora on the other hand, aims to incorporate the latest versions of software. Debian aims for stability and trail a distribution like Fedora by several versions (and bugs!).



     
    How do I install Linux?

    Linux can be installed as the sole operating system on a computer. This is the simplest solution and one should consult their selected distribution documentation for the instructions as the installation process will vary between distributions.

    Linux can also be installed alongside another operating system, for example, Windows. This is called a "dual-boot" configuration. A boot manager displays the choices for operating system when the computer is starting up and one can choose the OS at that time. To switch operating system, simply reboot and choose the other operating system from the boot manager. Here is a tutorial that illustrates what is involved in dual booting. Again, consult the documentation provided with one's distribution as there may be applications to streamline this process provided.

    Many distributions provide a Live CD which is a bootable CD or DVD that one can use to boot into a Linux OS without actually installing it on a hard drive. Knoppix is one popular distribution that has a bootable CD. It is full-featured, including office software and numerous programming languages and utilities. I have rescued data from numerous crashed Windows computers using Knoppix and highly recommend it. Ubuntu and Gentoo among others provide a Live CD which can be used to install the OS on a hard drive. There are many others, often with specific purposes like desktop replacement, system rescue, media playback, clustering and so on.

    One disadvantage to a Live CD install is that one cannot save changes or documents. Another option is to put the Live CD image on a USB flash drive and make it "persistent", that is, create space on the flash drive to save changes. The Ubuntu Wiki has instructions and a tool to create such a drive. UNetbootin is another tool which can create persistent flash drive installs form many distributions. PenDriveLinux has instructions for several other distributions, as well as their own. These installs usually require a 1Gb or larger flash drive.

    It is also possible to install Linux to a USB drive directly, though there are some steps one should take to optimize performance and insure the life of your flash memory (it can wear out!). This will require a larger flash drive than the previous option (Ubuntu installed weighs in at 2Gb+). There is a step-by-step guide to installing and configuring Ubuntu, but keep in mind they are for a particular class and not for the latest 9.04 release, so not all instructions will apply.

    Another option for installing Linux is to use a virtualization product like VirtualBox or VMware Player. These products allow one OS to host another OS in a virtual environment.

    VMWare provides a number of preconfigured virtual environments (what they term "appliances") including several Linux distributions and Solaris 10. If one requires a distribution that is not provided or would like to create a custom distribution, VMware offers a 30-day free free trial of VMware Workstation which can create and manage virtual machines. It is also possible to create a virtual machine without VMware Workstation using this online utility.



     
    What is The Best Linux Distribution?

    Short answer: There Isn't One

    Long answer: It depends on what you want to use your computer for. There may be a distribution tailored for exactly what you want. For example, if one wanted to install the Tivo-like Linux application MythTV but was intimidated by the prospect of discovering and installing the various prerequesites for the MythTV application, there is a distribution custom-built to support it: KnoppMyth. Conversely, KnoppMyth would probably be a poor choice if one wanted to build a web server.

    Here is a handy quiz to help you determine which distribution is for you. It asks questions about your hardware and needs and gives you a few options to consider.

    That being said, here is a list of popular Linux Distributions for various purposes. It is by no means complete:

    Desktop OS
    UbuntuVery popular distro because of simple set up and maintenance. Has huge community and a lot of software available.
    GentooHas great package management, tweaker's delight, requires advanced knowledge and time to adminster.
    FedoraA popular distribution championed by RedHat, bleeding-edge so be prepared for problems.
    openSUSESolid, simple to administer desktop distro.
    Debian
    MintBased on either Ubuntu or Debian
    Server OS
    Red Hat Enterprise ServerFully supported enterprise OS (of course, support costs money, so RHEL can be expensive). Even the most recent versions of RHEL are based on source code which is often several years old, which is a good thing if you want stability and reliablilty over bleeding-edge capabilities.
    CentOSA no-cost enterprise OS built from the mostly same source as RHEL and binary compatible with RHEL. CentOS releases lag only slightly behind RHEL.
    SUSE Enterprise 10Fully supported distro from Novell
    Utility Distros
    KnoppixBootable CD/DVD with complete desktop environment
    Pendrive LinuxTutorials and tools to make a bootable flash drive - can be made persistent so one can save changes
    Damn Small Linux (DSL)Very capable 50MB distro boots from business card CD or USB pen drive
    Scientific LinuxAnother independent reconstitution of RHEL, this time by Fermilab, CERN and others (hence the name)
    System Rescue CDBootable CD with all the tools for system rescue/recovery


    For more distributions, information, links to reviews, news and so on, have a gander at Distrowatch.



     
    How do I learn Linux?

    There's no shortage of information about Linux on the net. Every distribution will have a forum, mailing list, IRC channel or other conversational medium for users to help each other (see Ubuntu Forums for one example). These resources should be your first stop when you have a question about a particular distribution. They are also useful when selecting a distro, as knowledgable users will often engage in polite debate about a distro's suitability for a particular task.

    For general Linux information, The Linux Documentation Project has numerous FAQ's, HOWTO's, guides and other information. Linux Journal is one of a number of Linux-related magazines that run both general interest and highly technical articles.

    For the basics on how to use the command line, see Conquering the Bash Shell chapter of "Learning Debian GNU/Linux". The rest of the book is fairly dated, but that chapter is an excellent introduction to Bash. The shell is a very powerful tool in *nix, as opposed to the anemic command line in Windows and it is worth the time to learn some of the tricks of using it effectively. For more on shell programming, see Advanced Bash-Scripting Guide.



     
    How do I install Java?

    First, check your distribution documentation. Many distributions include OpenJDK (open source implementation of JDK) or make it available through their package management system. Oracle JDK can be available through third-party repositories.

    On Ubuntu and its derivatives (like Linux Mint) one can use UbuntuJavaInstaller script that automatically installs Oracle JDK from provided distribution file. The file needs to be downloaded from Oracle website first.

    Gentoo provides a shell Portage package but it is necessary to download the Java distribution manually as well.

    If your distribution doesn't provide any specific way to install Java, one can install it manually by following the instructions in the Oracle JDK Installation Guide.

    Note: If your Java applications perform poorly on Linux, check to see if your distribution installed the Gnu Compiler for Java as Ubuntu does with the java-gcj-compat package. In my experience, the gij interpreter included with GCJ performs very poorly compared to Oracle's VM.


     
    What is the cause of the "Can't connect to X11 window server" message?

    The short answer is that the JVM needs to be run with the java.awt.headless=true property set.

    The long answer is provided here.


     
    What makes Free Software "Free"?

    As the GNU Project web site states: "Free software" is a matter of liberty, not price.. Free software is a matter of the users' freedom to run, copy, distribute, study, change and improve the software."


     
    Links to other useful information

  • Introduction to the screen utility
  • Bash Guide for Beginners
  • Eric S. Raymond The Art of Unix Programming



  • CategoryFaq
     
    With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
      Bookmark Topic Watch Topic
    • New Topic