Echylo Posted August 9, 2004 Report Share Posted August 9, 2004 (edited) Well I was bored(gentoo is installing ;) ). So I was wondering if there was already a semi-Auto installation script for Gentoo, so I started to make one, as it is my first script, and probarly far from finished, there wil be some bugs in it :) . Just wondering what you all think of it #!bin/bash#Gentoo Installation Script(x86)(2004.2) #Installs from Mandrake on Partitions #Made by Echylo #Contact: driesdesmet@linux.be or dries.de.smet@skynet.be #Checks if user is root if [ `id -u` != "0" ]; then echo "Gentoo Installation Script 2004.2" echo "Sorry, you are not root." echo "Please restart script as root." fi #When user is , it gives information about the script echo echo "This script installs Gentoo from Mandrake" echo "So no Live cd required" echo "Created by Echylo" echo "This is for x86 machines only." echo "Working internet connection required" echo "To continue press a key..." read key #Gives user opportunity to check its partitions echo "The script will launch DiskDrake, for you to set partitions..." echo "If set, just close Diskdrake" echo "Press any key to continue" read key echo "Launching DiskDrake..." diskdrake echo "I suppose that you have set partitions, and you are ready to continue" echo "Press a key to continue" read key #Asks for boot, swap and home partition echo "What is the boot partition of your gentoo installation?" echo "Example : /dev/hdb1" read BOOTPART echo "What is the Swap partition?" read SWAP echo "What is your Gentoo(home) partition?" read GENTOOHOME #Activates Swap partition, mounts boot & home partition mkswap $SWAP swapon $SWAP mkdir /mnt/gentoo mount $BOOTPART /mnt/gentoo mkdir /mnt/gentoo/boot mount $GENTOOHOME /mnt/gentoo/boot #Downloading stage file cd /mnt/gentoo echo "Downloading Stage file..." echo "Choose your location...(1-4)" echo "1- America" echo "2 - Europe" echo "3 - Australia" echo "4 - Asia" echo echo "Pick number:" read LOC if [ $LOC -eq 1 ] then echo "Downloading Stage 1 file..." wget ftp://gentoo.chem.wisc.edu/gentoo/release...-2004.2.tar.bz2 elif [ $LOC -eq 2 ] then echo "Downloading Stage 1 file..." wget ftp://ftp.snt.utwente.nl/pub/os/linux/gen...-2004.2.tar.bz2 elif [ $LOC -eq 3 ] then echo "Downloading Stage 1 file..." wget ftp://planetmirror.com/pub/gentoo/release...-2004.2.tar.bz2 elif [ $LOC -eq 4 ] then echo "Downloading Stage 1 file..." wget ftp://ftp.ecc.u-tokyo.ac.jp/GENTOO/releas...-2004.2.tar.bz2 else echo "You have to pick a number between (1-4)!" echo "Downloading Stage 1 file from default..." wget ftp://gentoo.chem.wisc.edu/gentoo/release...-2004.2.tar.bz2 fi #Unpacks Stage1 tar file clear echo echo "Stage 1 file Downloaded" echo "Unpacking Stage 1 file..." tar -xjpf stage1-x86-2004.2.tar.bz2 echo "Unpacked" echo #Copies DNS information echo "Copying DNS information" cp -L /etc/resolv.conf /mnt/gentoo/etc/resolv.conf #Mounts Proc filesystem echo "Mounting proc filesystem" mount -t proc none /mnt/gentoo/proc #Chroots into new Enviroment" echo "Chrooting into Enviroment" chroot /mnt/gentoo /bin/bash env-update source /etc/profile #Updates Portage Tree" echo "Updating Portage tree" emerge sync cd /usr/portage #Stage 1 -> Stage 2 echo "Stage 1 => Stage 2 " echo "Press key to continue" read key echo "BootStraping..." scripts/bootstrap.sh echo "Arrived in Stage 2" #Emerging system echo "Emerging system" emerge system #script finished until here :) Edited August 9, 2004 by Echylo Quote Link to comment Share on other sites More sharing options...
Echylo Posted September 15, 2004 Author Report Share Posted September 15, 2004 *sortofbump* is this a good idea, should I work it further out or not? Quote Link to comment Share on other sites More sharing options...
Windependent Posted November 9, 2004 Report Share Posted November 9, 2004 right now i'm in the midst of a Stage 1 installation, and i'm killing time during bootstrapping. yeah, an automated gentoo install script would be sort of a dream come true... Quote Link to comment Share on other sites More sharing options...
arctic Posted November 9, 2004 Report Share Posted November 9, 2004 (edited) i wish i would have had such a script some weeks ago. installing gentoo was a pain in the a... continue your work. it is a great idea. p.s.: now that i have gentoo running, i must say that i do not find it better or worse than e.g. slackware (and configuration an installation of slack was easy compared to gentoo). it is just another ordinary linux-distro. too much hype imho :P Edited November 9, 2004 by arctic Quote Link to comment Share on other sites More sharing options...
Padma Posted November 14, 2004 Report Share Posted November 14, 2004 Just to give you a laugh -- I tried your script, and accidentally gave it the wrong partition for 'swap'. I ended up destroying my Mandrake '/' partition. :lol: It could have been worse - it forced me to reinstall 10.1, and this time it is cleaner and better. ;) Quote Link to comment Share on other sites More sharing options...
Echylo Posted November 14, 2004 Author Report Share Posted November 14, 2004 omg :P sorry , and I don't think I will continue working on it, working with Ubuntu now, so no time for gentoo :P Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.