Halaman

Papua

Papua
is the bwest of Papua

Senin, 10 Oktober 2011

Debian GNU/Linux (Etch) Installation Tutorial (net install)

No worries that Etch isn't released yet. It's been frozen for months -- stable and reliable for longer than that. I was hesitant to write up a tutorial on its install until it was released. However, it no longer seems prudent to wait. Installing Etch is probably one of the easiest tasks that one can do. Computer wise or not -- people can walk to the store, chew gum AND have an idea at the same time -- so in this respect, installing Debian on your computer is a very simple thing, indeed.This Debian installation tutorial has been modified since I initially wrote it last week, even though you don't need it.

BONUS:

Folks that wish to switch to Debian but may have reservations about burning an .ISO image can now do it from within their Windows installation. Like installing any Windows app. Get that program hereRight off the bat you should know that there are myriad ways of installing Debian. Since I'm lazy and impatient -- and like to believe that I am efficient as well, I go pretty minimal and yet my desktop is complete. Net installer (i386, amd64) is what I get and use to install Debian. (See the Readme for the Lenny net installer.) It's quick with a fast internet connection as only the basic Linux functionality can be installed initially and after your first reboot you can get things going quickly. I have a desktop in 1/2 hour from the first boot. Sweet!

Summary Task List


  • boot to a utility to manage the partitions on my hard drive
  • reboot to run the Debian installer, I use net installer
  • choose no programs to install when I'm prompted, just laptop and or base system
  • yes to grub
  • upon reboot, mod sources.list, apt-get update:
    deb http://debian.uchicago.edu/debian/ etch main contrib non-free
    deb-src http://debian.uchicago.edu/debian/ etch main contrib non-free
    
    deb http://security.debian.org/ etch/updates main contrib
    deb-src http://security.debian.org/ etch/updates main contrib
    #opera
    deb http://deb.opera.com/opera/ etch non-free
    #marillat
    deb http://mirror.home-dn.net/debian-multimedia/ etch main
    deb-src http://mirror.home-dn.net/debian-multimedia/ etch main
    
  • update the kernel, toss the headers on, reboot into it
  • apt-get install module-assistant build-essential
  • m-a prepare, m-a a-i nvidia, apt-get install nvidia-glx, modprobe nvidia [if applicable]
  • apt-get install (FOR LAPTOP INCLUDE ---> powernowd cpufrequtils) gnome-core xorg gdm synaptic alsa-base alsa-utils alsa-oss mplayer opera ffmpeg mozplugger sylpheed-claws-gtk2 bogofilter
  • nano /etc/X11/xorg.conf to manually update xorg, or run
    # dpkg-reconfigure xserver-xorg
  • log out as root, login as me, startx
  • Open Synaptic and start messing about with packages
Let's break it down...

boot to a utility to manage the partitions on my hard drive

What we want to do first is consider our hard disk partitions. Chances are you already have 1 large partition formatted fat32 or ntfs. If you want to keep your Windows install that's fine. You can. However, if you want to nuke it then you can do that as well. We boot to a utility disc because managing your partitions is done when you're not using them. System Rescue CDis the disc that I use when I want to run utilities on a computer. There are others, knock yourself out -- we'll be using qtparted. You can see a tutorial that uses this utility here Warning -- it looks like ass in Opera. It's here as well.
What you want to do is make sure that your hard drive has a spot to install Debian onto. You may currently have one large partition filling all the available space on your hard drive. You'd have to re-size that partition or buy another hard drive. Starting off pretty simply, and let's say that you're keeping Windows installed for now and you'll be dual-booting. Hey -- there's no **cough** shame **cough** in this. Let's decide right now about your partition structure and let's go with something like this:
   Device    Boot      Partition Size	Partition	System
/dev/hda1     *           10GB		NTFS		Windows
/dev/hda2                 1GB		Swap		Linux
/dev/hda3                 10GB		/     - ext3	Linux
/dev/hda4              	  19GB		/home - ext3	Linux
Obviously, the partition sizes will differ from what you've actually got. You can see that we have (or have made...) 4 primary partitions. That's all the primaries that you can have on a partition. You can have as many logical partitions within an extended partition that you want, but you can get all Rico Suave with your partitions later. You'll notice as well that the dev/hda partition, the Windows one, has an asterisk in the line -- that signifies that the partition is start-able or boot-able. Again -- the web is fantastico -- if you want to get fancy with your partitions then go ahead. If you want to forget about this and the preceding paragraphs and let the Debian install routine handle your partitions, then that's cool, too. Because it can -- you can delete and create. You can do more, but let's stay focused.

reboot to run the Debian installer

Now that you've considered your partitions, we boot to the Debian installation disc that you downloaded and burned. In case you are pulling your hair out with all of this "boot to this...boot to that..." stuff, plenty of excellent information can be had in forums or by well-rehearsed Google queries.
When you boot to your Debian install disc you will see this prompt (never-mind that linux26 command). At it, you have the opportunity to poke around, get extra info on how to install. If you hit F1 - F5 you'll learn about some install arguments and instructions that you can give the installer. It's all tres geek, but ya know -- this kind of functionality is important.
You can simply hit your enter key at the prompt, or enter installgui if you want to use the new graphical installer. But, why would you? Installing Debian is, well -- drop-dead simple.
When the installer starts you've got some selections to make. Mostly - it picks "sane defaults" and you'll be hitting enter quite a bit. Pick your language, time zone, that sort of thing. It will detect your hard disk next and load necessary drivers to find your cd-rom. The installer will buzz through few things, you'll see things being loaded. Like a kernel and utilities.
Your next prompt is for networking. You'll see "configuring network with DHCP" and if you're plugged into a router or have an internet connection already you'll see that it succeeds and you'll be prompted for your hostname next. If the network configuration fails, say because you have a connection that uses pppoe like I do from Verizon, than don't sweat it. Simply arrow to "don't configure network at this time" so we can do it later.
Now, at the hostname prompt, pick one. This is the name of your computer. You can use salty-dog if you like. Or, whatever -- type something in. If the network auto-negotiation worked you may see your domain name already filled in on the next screen. If no, don't worry. blank is fine.

Partitions

Disks will be detected next and the partition utility will start. You have options here. Debian does a pretty good job if you choose Guided - use entire disk (don't choose this if you're keeping Windows around ;) ). You can choose to use encryption at this time as well. It failed for me the last time I tried to use encrypted discs. I always choose the manual option so I can set my partitions up the way that I like.
You already set your partitions up so the installer simply wants you to tell it onto which partitions you would like to mount what. Go ahead and choose the manual option.
The installer will offer you some help here. Pick it if you like as there is no time limit to get this installed. Go ahead and read everything if you like. I arrow to the hard disk that I want to set up. If you have more than one place that the installer sees suitable to install Debian onto, you will see a list. How about for now we choose the first hard drive, IDE1 (hda). (Or, sda if that's the case).

need to create partitions, new drive

If you're using a new hard drive you probably won't have a partition table set up yet. The installer will give you a heads-up. In this case, you'll be creating partitions because you chose not to do this with the system disc that I wrote about earlier. No sweat. The installer can do this for you. You choose create a new partition or Let Debian do it and choose Automatically partition the free space. I'll choose the automatic option as I don't think I've ever done it before. I did and I was prompted now for the partitioning scheme. The installer asks if I want all files in one partition (hell no, even tough it's the one recommended for new users), separate /home partition, or separate /home, /var, etc. That's the one that I choose -- separate your stuff, it's good-medicine.
The installer created your partitions and mounts them appropriately. It will present you with the results and you'll probably see a primary partition and a bunch of logical ones, too. Now click on finish partitioning and write changes to disk. It'll ask you if you're serious next -- which bugs me -- tell it yes.

already have partitions set up

If you have already set your partitions up then when the disk partition utility starts, and you see your list of places to install Debian -- you need only arrow through your listed partitions and choose file-system, where to mount, labels, sizes and all that.
You can see a pic here. Also, see this image. Use your arrow and enter keys to make choices here.
Remember -- you have already made your partitions, so you're really just assigning a file-system and mount point. Don't forget to make sure that your Xda1 partition is boot-able. You choose this when you're going through your partitions assigning blame, ahem, I mean mounts. You'll see a boot-able flag option. Make sure it reads on for your start-able partition. If you let the installer set your partitions up it makes your appropriate partition boot-able.

Continuing

Following the disk partition utility part of the show, the installer presents you with time zone options, and you'll choose a root password. Um, pick a good one. Really. PICK A GOOD ONE. Next, create one regular user. Now the installer begins to install your base system. I'll be right back, I'm gonna go have a smoke...
After Debian puts its base system on your hard drive you'll configure apt. Apt is your package management system. Other, lesser, operating systems wished they had the Debian apt implementation. Go ahead and pick a mirror close to you. I leave the proxy empty -- but if you know that you have one, get that info from whomever might know it...Apt will scan the mirror you chose, it may even stall for a minute, mine often does at 40% --
You may choose to participate in the package usage survey next, if you like. Sometimes I do, sometimes I don't. No harm either way. (I know! Take a breath.)

choose no programs to install when I'm prompted

Don't do it. You'll see a list in front of you. You may choose a desktop environment in which a Gnome desktop will be installed. It's actually not bad, and it's not a complete Gnome install. I never do it. But, hey -- and I'm serious -- do what you like. In fact, choose the desktop option, that's what it's there for. I'm a Gnome, Xfce4, and bare-ass server happiness man myself. You can use your arrow keys and space bar to navigate and select items in this list. If you're installing Debian on a laptop then go ahead and make sure that you select Laptop. At this point I only have standard system selected. Enter to continue...I see that the installer has chosen 103 packages to download and install from my bare selection. Cool, this takes no time at all.

yes to grub

How cake is this, by the way? Yes to Grub. You may not see this prompt, for grub, I just didn't. I saw the [!!] finish the installation prompt. I hit enter to allow my machine to reboot.

upon reboot, mod sources.list, apt-get update

Etch is installed. You'll see that you rebooted into a terminal screen. You can login as root since you still have to actually set your desktop up now. What we want to do now is set up your repository list. You've got one right now, type: nano /etc/apt/sources.list right now to open it. You're going to anyway. Remember, earlier we went through that quickie apt config during the install process. These addresses that you see in your sources.list are what was written then. go ahead, arrow to the beginning of the cd-rom line. Should be the top 2. Put a # symbol at the beginning of each line. We don't want to use these repos anymore. You can see the repo list that I use in the summary, above, in this article. Choose. Now -- non-free or not? Do you care? Probably not. For some purposes you will need the non-free repos.
I'm in New England, USA, so my repo mirrors will be different than yours. For now, as a generic sources.list file, you can check out what Debian has to write about apt. Or, use these for now:
deb http://http.us.debian.org/debian/ etch main contrib non-free 
deb-src http://http.us.debian.org/debian/ etch main contrib non-free 

replace the us with your own country's abbreviationDon't forget to add the marillat repos for your codec bliss.
ctrl + x to exit, y to save, and enter to overwrite your original.
# apt-get update

update the kernel, toss the headers on, reboot into it

What you've got is a generic 486 kernel installed. Fine. You may keep it and run forever happy. Or, you can install one a little more tuned to your processor. I have an AMD AthlonXP chip, so I install the k7 kernel with headers at this time. I want to immediately reboot my machine into this new kernel to continue setting my machine up, too. You can use
# apt-cache search linux-image to get a list of the kernels you may choose from to install. Likely you'll at least go with a 686 choice. This is what I do:
# apt-get install linux-image-2.6.18-3-k7 linux-headers-2.6.18-3-k7
Then, I reboot.
Back up, and in my new kernel, I continue. Let's...

apt-get install module-assistant build-essential

We always install build-essential. Installing module-assistant now will pay off. If you've got need for kernel-modules like a web cam or you have an nvidia graphics card, you'll dig module-assistant. Promise. You don't have to piece-meal the rest of your desktop installation, though. You are at the point where your system is ready for everything. What you're looking for now is a desktop environment and the display environment to run everything in. You can either only install those right now, or install the whole shebang all at once. In which case you'll have some down time. On my buddies wicked fast cable connection everything was installed in 7 minutes. Christ that was fast. If you want to get right to a desktop, let's go...
# apt-get install gnome-core xorg
That's it. Your next command can be to exit root, login as the regular user you made at install and enter startx at the prompt.
But I don't do that now. I do...

m-a prepare, m-a a-i nvidia, apt-get install nvidia-glx, modprobe nvidia [if applicable]

...because this machine has an nvidia display card. Before I install Gnome, et al, I get my audio and video all set up. For my hardware this is a cinch. First off I get sound working:
# apt-get install alsa-base alsa-utils alsa-oss
When it's finished I run # alsaconf. Check -- sound's done.
For the video, module-assistant is handy to get my nvidia drivers installed. Check this wicked handy nvidia driver install tutorial. Just the module assistant part, start at m-a prepare, you're finished at modprobe nvidia. Fast and simple, I promise, and come right back.
OK -- You're back. This is the point where I actually install everything because when I do login as me and startx I want everything squared away. On my desktop machines I run this now:
# apt-get install zip unzip ffmpeg mozplugger mplayer gnome-core gdm libdvdcss2 revelation xorg build-essential gnome-volume-manager xmms cupsys hplip gtklp gaim gaim-encryption liferea synaptic bogofilter ffmpeg lm-sensors evince file-roller bzip2 prelink gnome-media glabels gnome-system-tools gnome-themes-extras sound-juicer totem-xine zenity imagemagick gftp gconf-editor openssl foomatic-filters-ppds foomatic-db-hpijs libgpgme11-dev cdcat ccrypt libnet-ssleay-perl xsane sensors-applet gnubiff sylpheed-claws-gtk2 sylpheed-claws-gtk2-pgpmime abiword abiword-plugins gnumeric gnumeric-plugins-extra apt-spy unclutter gdebi opera
On my laptop I usually just run this install command and pick and choose later in Synaptic:
# apt-get install gnome-core xorg powernowd cpufrequtils mozplugger mplayer opera ffmpeg libdvdcss2
It's so subjective -- this package installation. Who knows what you want to do with your machine?
When the desktop installation is finished you will be left at your root prompt. You'll still see the # symbol, letting you know. Go ahead and exit root. Login as you and then startx to get your graphical display going. After a reboot you won't have to startx anymore, the graphical desktop environment will load.
We're finished. See, that was easy -- and it took no time. Start to expect this sort of thing with your shiny new (even if you're on 7 year old hardware) Debian desktop.
I hope that this tutorial was helpful to you.

Tidak ada komentar:

Posting Komentar