LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - General (http://www.linuxquestions.org/questions/linux-general-1/)
-   -   Creating a continuous 2cd custom installer using Centos? (http://www.linuxquestions.org/questions/linux-general-1/creating-a-continuous-2cd-custom-installer-using-centos-691156/)

infernal211283_ 12-17-2008 03:40 AM

Creating a continuous 2cd custom installer using Centos?
 
Hi,
I currently have a task to create a continuous installer with 2 or more CDs.

Anaconda installer does it and I think that there shouldn't be a problem to adopt it.
I guess the anaconda installer knows which cd is required according to the files located on the CDs set, and knows when a correct cd was inserted according to .discinfo...

My setup will be much simpler though:
I want the first cd to be the one that deploys the OS on a server using kickstart, and when it's done, the user will be asked to switch the cds.

Are there tools or system calls that I can use to be able to tell:
-) if a cd is in a tray,
-) when the tray changes it's state from closed to open,
-) when the tray changes it's state from open to closed ?

Any help will be much appreciated,

Thanks,
Dan.

unSpawn 12-17-2008 04:44 PM

Quote:

Originally Posted by infernal211283_ (Post 3378304)
if a cd is in a tray,

Wouldn't a check of /proc/ide/devicename/capacity return >0? Or else look in /proc/sys/dev/cdrom/ for disk or tray info? Or else figure something out with the CDROM_DRIVE_STATUS and CDROM_DISC_STATUS ioctls like 'eject' uses or else see example in /kernel source/Documentation/cdrom/ide-cd?

ncsuapex 12-17-2008 09:03 PM

You mean create an install that has 2 CDs? Like CD1 is the boot/install 1 CD and CD2 has additional software? When you get this completed please post the steps. I might need to do this one day.


Oh and any chance you could just make it one DVD instead of 2 CDs? Or are you needing it for CDROMs only drives?

infernal211283_ 12-18-2008 07:32 AM

unSpawn, thank you for pointing me in those directions.

The capacity file does look like it can help,
I wondered what will happen is the cdrom will be scsi and the device block will change to sda, so the final line to check whether there's a cd inserted, looks like this:

cat /proc/ide/"$(dmesg |grep CD-ROM|awk -F\: 'NR==1 {print $1}')"/capacity

One more thing left to do is to adopt the .discinfo file so the installer will know that's the right cd.
Looks like something that can be achieved, thanks again for your help.

ncsuapex,
I'll have to do both, DVD and split CD set.

I'll post the outcome when I'm done with this.

zwli 04-01-2011 05:17 AM

Quote:

Originally Posted by infernal211283_ (Post 3379879)
unSpawn, thank you for pointing me in those directions.

The capacity file does look like it can help,
I wondered what will happen is the cdrom will be scsi and the device block will change to sda, so the final line to check whether there's a cd inserted, looks like this:

cat /proc/ide/"$(dmesg |grep CD-ROM|awk -F\: 'NR==1 {print $1}')"/capacity

One more thing left to do is to adopt the .discinfo file so the installer will know that's the right cd.
Looks like something that can be achieved, thanks again for your help.

ncsuapex,
I'll have to do both, DVD and split CD set.

I'll post the outcome when I'm done with this.

hi, Dan
what's your final solution about this problem? i also encounterred the same question :(

onebuck 04-01-2011 07:18 AM

Hi,

Welcome to LQ!

You should look at the post(s) date. infernal211283_ has not posted for over 2 years.

Do not resurrect such old threads. If you have a query then create a new thread and include complete information as to the query.

You should use descriptive titles for your threads. That way you will receive targeted responses.



FYI: I suggest that you look at 'How to Ask Questions the Smart Way' so in the future your queries provide information that will aid us in diagnosis of the problem or query.


All times are GMT -5. The time now is 02:34 PM.