LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 09-06-2009, 08:15 PM   #1
Fred Caro
Senior Member
 
Registered: May 2007
Posts: 1,007

Rep: Reputation: 167Reputation: 167
install o/s by command line


in ignorance,
I have a h.drive with several linux o/s's on and have partitioned and formated another partition using fdisk how do I install another os using a cd (or other) via the command line? I know there are easier ways but is there a command line event and what is the 'code'.

Roy.
 
Old 09-06-2009, 08:18 PM   #2
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.2
Posts: 18,348

Rep: Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749Reputation: 2749
If it's Linux, boot the install media and it should ask you which partition(s) to use.
 
Old 09-07-2009, 12:54 AM   #3
Fred Caro
Senior Member
 
Registered: May 2007
Posts: 1,007

Original Poster
Rep: Reputation: 167Reputation: 167
install os (linux) using cml

sorry, I have not made myself clear. It seems a disappointment after struggling with the fdisk to revert to ease of use. Is there an install command to install an os and then choose your media? Or define your media pre-insert,etc then go ahead otherwise there seems little point in the fdisk as a new 'version' exists on modern installation disks. If that is not too contradictory.

Fred.
 
Old 09-07-2009, 01:19 AM   #4
vishesh
Member
 
Registered: Feb 2008
Distribution: Fedora,RHEL,Ubuntu
Posts: 661

Rep: Reputation: 66
If your os in in form of rpm (redhat ) or in tar format there there may be way to install it, there is no need of special command This is what my logic says.

Last edited by vishesh; 09-07-2009 at 01:21 AM.
 
Old 09-07-2009, 01:38 AM   #5
linuxlover.chaitanya
Senior Member
 
Registered: Apr 2008
Location: Gurgaon, India
Distribution: Cent OS 6/7
Posts: 4,631

Rep: Reputation: Disabled
If you are using RH or CentOS, then you can boot from first disk, and then use the askmethod option to choose from the method.
If you want to use text mode, you can use text option to install directly from media using text mode.
 
Old 09-07-2009, 11:00 AM   #6
salasi
Senior Member
 
Registered: Jul 2007
Location: Directly above centre of the earth, UK
Distribution: SuSE, plus some hopping
Posts: 4,070

Rep: Reputation: 897Reputation: 897Reputation: 897Reputation: 897Reputation: 897Reputation: 897Reputation: 897
Quote:
Originally Posted by Fred Caro View Post
I have a h.drive
Did you mean "hard drive" or something that you are calling an "H drive"?
H drive is terminology used by some other OS and is not meaningful here.

Quote:
...have partitioned and formated another partition using fdisk how do I install another os using a cd (or other) via the command line?
If you plug the CD (/DVD) in and boot from that, you will run the installer for that OS. If you don't want a graphical install, you will have to use an OS version that has a non-graphical install (in some cases that is an option that you select at boot time, in other cases its a different download).

If you want to do this from a usb device, it will need to be on a computer that has 'boot from usb' as a bios option.

Quote:
...what is the 'code'.
It is what runs when you boot. Its a program, or collection of programs. It runs.

Quote:
sorry, I have not made myself clear. It seems a disappointment after struggling with the fdisk to revert to ease of use.
Well the initial question was somewhat unclear, but i can't imagine a question that would be made appreciably clearer by that. What do you mean by "to revert to ease of use"?

AFAICT this seems irrelevant to the question, but my misunderstanding may just have greater depth than I thought.

Quote:
Or define your media pre-insert,etc
Do you mean the partitioning that you have done? Defining the boot source (bios)?

I think you may be asking something very, very easy. Here are the instructions:

Boot the install media. Use the install program. Use its partitioning/formatting options. Let the install proceed.

Now, what else were you asking?
 
Old 09-07-2009, 11:33 AM   #7
New2Linux2
Member
 
Registered: Jan 2004
Location: Arizona
Distribution: Debian
Posts: 153

Rep: Reputation: 43
It would seem that the OP's original question is "Can I install a new OS from the command line of an existing OS without having to boot to the install media?" (If I'm wrong, please disregard this post.)

To my knowledge, the new OS installer works when you boot from the install media (in this case, the CD.) However, if you use a virtual machine (VMWare and the like) you can install an image of the new OS to use in a virtual environment without having to boot to the install the media. Other than that, I think you need to install the OS by restarting the computer with the CD in the drive and boot from it instead of the OS that is currently installed on your hard drive.
 
Old 09-07-2009, 01:25 PM   #8
btmiller
Senior Member
 
Registered: May 2004
Location: In the DC 'burbs
Distribution: Arch, Scientific Linux, Debian, Ubuntu
Posts: 4,290

Rep: Reputation: 378Reputation: 378Reputation: 378Reputation: 378
If the OP wants to install a new OS from scratch from inside an existing OS, using the command line, then he might want to take a look at Linux From Scratch. It goes through how to do exactly that. In principle, any Linux distro can be installed "from scratch" inside another, just by performing the same commands that the install routine would perform.
 
Old 09-08-2009, 04:20 PM   #9
Fred Caro
Senior Member
 
Registered: May 2007
Posts: 1,007

Original Poster
Rep: Reputation: 167Reputation: 167
chiatanya

No I'm not on Red Hat, or even Fedora, but I get your drift. What is the text, writing, to start and install an o/s on a pre-prepared disk (unmounted),eg, sda or hda 5 on any bash line be it Debian or R/H?

Fred.
p.s.
Please excuse my ignorance.
 
Old 09-08-2009, 05:43 PM   #10
onebuck
Moderator
 
Registered: Jan 2005
Location: Central Florida 20 minutes from Disney World
Distribution: Slackware®
Posts: 13,922
Blog Entries: 44

Rep: Reputation: 3158Reputation: 3158Reputation: 3158Reputation: 3158Reputation: 3158Reputation: 3158Reputation: 3158Reputation: 3158Reputation: 3158Reputation: 3158Reputation: 3158
Hi,
Quote:
Originally Posted by Fred Caro View Post
No I'm not on Red Hat, or even Fedora, but I get your drift. What is the text, writing, to start and install an o/s on a pre-prepared disk (unmounted),eg, sda or hda 5 on any bash line be it Debian or R/H?

Fred.
p.s.
Please excuse my ignorance.
What operating system are you using now?

As for the prepared partition you can use that as your install partition when you boot an installer for the GNU/Linux Distribution of choice as long as there is enough space for the filesystem. Once booted you would direct the installer to that partition. Each Distribution handles the install differently but generally you will need to use the installer for the distribution you choose.

As an example with Slackware you can use the 'USB & PXE' install method other than the cd/dvd but you still need to prepare the USB for the installer then you redirect after the boot of the USB either to boot PXE or USB install. Generalized explanation but most installers must take control of your install machine to continue with any install.

Now if your speaking of upgrading or package installs then that another method entirely for most distributions.
 
Old 09-09-2009, 03:10 AM   #11
Fred Caro
Senior Member
 
Registered: May 2007
Posts: 1,007

Original Poster
Rep: Reputation: 167Reputation: 167
install

Dear Onebuck,
what you say makes sense,especially, about the 'installation' taking control of the system but I take it you cannot issue a string of 'commands' to set up the install of an o/s.

Fred.
 
Old 09-09-2009, 08:39 AM   #12
onebuck
Moderator
 
Registered: Jan 2005
Location: Central Florida 20 minutes from Disney World
Distribution: Slackware®
Posts: 13,922
Blog Entries: 44

Rep: Reputation: 3158Reputation: 3158Reputation: 3158Reputation: 3158Reputation: 3158Reputation: 3158Reputation: 3158Reputation: 3158Reputation: 3158Reputation: 3158Reputation: 3158
Hi,
Quote:
Originally Posted by Fred Caro View Post
Dear Onebuck,
what you say makes sense,especially, about the 'installation' taking control of the system but I take it you cannot issue a string of 'commands' to set up the install of an o/s.

Fred.
Yes, you can enter a string on the command line. First, place the boot media of choice in the device of choice. Then from the command line 'shutdown -r now' will boot the device that is designated after the shutdown of the system and then rebooting.
 
Old 09-09-2009, 09:51 AM   #13
i92guboj
Gentoo support team
 
Registered: May 2008
Location: Lucena, Córdoba (Spain)
Distribution: Gentoo
Posts: 4,083

Rep: Reputation: 405Reputation: 405Reputation: 405Reputation: 405Reputation: 405
Each Linux distro has a different installation method, some of then can be invoked or faked easily from an already installed system, however you will always need some understanding about how partitioning works, about how the bootloaders can be configured, and about some other things.

Gentoo or LFS are typical examples of Linuxes that can be installed from the commands line of an already working Linux that you have installed. In fact you could be installing Gentoo using an xterm in your Fedora desktop while surfing the net or killing some aliens. But they are not the only ones, for example, the process is well documented for Debian:

http://www.debian.org/releases/stabl...apds03.html.en

Knoppix has an installer that can also be launched from the command line, so I guess that you should be able to mount the knoppix cd or squashfs image and then just launch it. I am sure that you could find instructions for some other Linuxes as well.

There's no standard way to just put any arbitrary Linux cd on the tray and just launch a single command to install it, since the process and the very format of the disk can vary from distro to distro. That's why most people just reboot into a livecd or an usb image and use that.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
How to install driver through command line? ahill713 Linux - Newbie 7 01-10-2008 11:31 AM
Serer install - cant see command line MisterGoof Ubuntu 1 08-24-2006 07:42 PM
DL and install X from command line NeoCzar Linux - Newbie 1 07-20-2005 10:12 PM
after install of 10.1 only have command line? robbymcw Mandriva 1 02-04-2005 09:08 AM
After Install No GUI just Command Line myristate Slackware 9 11-14-2004 06:18 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 02:53 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration