if (strcmp(serial_console, "yes") != 0) {
snprintf(commandstring, STRING_SIZE,
if (strcmp(serial_console, "yes") != 0) {
snprintf(commandstring, STRING_SIZE,
if (mysystem(commandstring)) {
errorbox("unattended: ERROR modifying inittab");
return 0;
}
snprintf(commandstring, STRING_SIZE,
if (mysystem(commandstring)) {
errorbox("unattended: ERROR modifying inittab");
return 0;
}
snprintf(commandstring, STRING_SIZE,
fprintf(flog, "unattended: setting root password\n");
snprintf(commandstring, STRING_SIZE,
fprintf(flog, "unattended: setting root password\n");
snprintf(commandstring, STRING_SIZE,
/* set admin password */
fprintf(flog, "unattended: setting admin password\n");
snprintf(commandstring, STRING_SIZE,
/* set admin password */
fprintf(flog, "unattended: setting admin password\n");
snprintf(commandstring, STRING_SIZE,
if (raid_disk)
snprintf(commandstring, STRING_SIZE, "/bin/mke2fs -T ext2 -c %sp1", hdparams.devnode);
if (raid_disk)
snprintf(commandstring, STRING_SIZE, "/bin/mke2fs -T ext2 -c %sp1", hdparams.devnode);
- snprintf(commandstring, STRING_SIZE, "/bin/mkswap %sp2", hdparams.devnode);
+ snprintf(commandstring, STRING_SIZE, "/sbin/mkswap %sp2", hdparams.devnode);
- snprintf(commandstring, STRING_SIZE, "/bin/mkswap %s2", hdparams.devnode);
+ snprintf(commandstring, STRING_SIZE, "/sbin/mkswap %s2", hdparams.devnode);
if (runcommandwithstatus(commandstring, ctr[TR_MAKING_SWAPSPACE]))
{
errorbox(ctr[TR_UNABLE_TO_MAKE_SWAPSPACE]);
if (runcommandwithstatus(commandstring, ctr[TR_MAKING_SWAPSPACE]))
{
errorbox(ctr[TR_UNABLE_TO_MAKE_SWAPSPACE]);
- snprintf(commandstring, STRING_SIZE, "/sbin/mount %sp3 /harddisk", hdparams.devnode);
+ snprintf(commandstring, STRING_SIZE, "/bin/mount %sp3 /harddisk", hdparams.devnode);
- snprintf(commandstring, STRING_SIZE, "/sbin/mount %s3 /harddisk", hdparams.devnode);
+ snprintf(commandstring, STRING_SIZE, "/bin/mount %s3 /harddisk", hdparams.devnode);
if (runcommandwithstatus(commandstring, ctr[TR_MOUNTING_ROOT_FILESYSTEM]))
{
errorbox(ctr[TR_UNABLE_TO_MOUNT_ROOT_FILESYSTEM]);
if (runcommandwithstatus(commandstring, ctr[TR_MOUNTING_ROOT_FILESYSTEM]))
{
errorbox(ctr[TR_UNABLE_TO_MOUNT_ROOT_FILESYSTEM]);
- snprintf(commandstring, STRING_SIZE, "/sbin/mount %sp1 /harddisk/boot", hdparams.devnode);
+ snprintf(commandstring, STRING_SIZE, "/bin/mount %sp1 /harddisk/boot", hdparams.devnode);
- snprintf(commandstring, STRING_SIZE, "/sbin/mount %s1 /harddisk/boot", hdparams.devnode);
+ snprintf(commandstring, STRING_SIZE, "/bin/mount %s1 /harddisk/boot", hdparams.devnode);
- snprintf(commandstring, STRING_SIZE, "/bin/swapon %sp2", hdparams.devnode);
+ snprintf(commandstring, STRING_SIZE, "/sbin/swapon %sp2", hdparams.devnode);
- snprintf(commandstring, STRING_SIZE, "/bin/swapon %s2", hdparams.devnode);
+ snprintf(commandstring, STRING_SIZE, "/sbin/swapon %s2", hdparams.devnode);
if (runcommandwithstatus(commandstring, ctr[TR_MOUNTING_SWAP_PARTITION]))
{
errorbox(ctr[TR_UNABLE_TO_MOUNT_SWAP_PARTITION]);
if (runcommandwithstatus(commandstring, ctr[TR_MOUNTING_SWAP_PARTITION]))
{
errorbox(ctr[TR_UNABLE_TO_MOUNT_SWAP_PARTITION]);
- snprintf(commandstring, STRING_SIZE, "/sbin/mount %sp4 /harddisk/var", hdparams.devnode);
+ snprintf(commandstring, STRING_SIZE, "/bin/mount %sp4 /harddisk/var", hdparams.devnode);
- snprintf(commandstring, STRING_SIZE, "/sbin/mount %s4 /harddisk/var", hdparams.devnode);
+ snprintf(commandstring, STRING_SIZE, "/bin/mount %s4 /harddisk/var", hdparams.devnode);
if (runcommandwithstatus(commandstring, ctr[TR_MOUNTING_LOG_FILESYSTEM]))
{
errorbox(ctr[TR_UNABLE_TO_MOUNT_LOG_FILESYSTEM]);
if (runcommandwithstatus(commandstring, ctr[TR_MOUNTING_LOG_FILESYSTEM]))
{
errorbox(ctr[TR_UNABLE_TO_MOUNT_LOG_FILESYSTEM]);
/* touch the modules.dep files */
snprintf(commandstring, STRING_SIZE,
/* touch the modules.dep files */
snprintf(commandstring, STRING_SIZE,
fprintf(flog, "Detected SCSI driver %s\n",driver);
if (strlen(driver) > 1) {
fprintf(flog, "Fixing up ipfirerd.img\n");
fprintf(flog, "Detected SCSI driver %s\n",driver);
if (strlen(driver) > 1) {
fprintf(flog, "Fixing up ipfirerd.img\n");
- snprintf(commandstring, STRING_SIZE, "/bin/chroot /harddisk /sbin/mkinitrd --with=scsi_mod --with=%s --with=sd_mod --with=sr_mod --with=libata /boot/ipfirerd.img %s", driver, KERNEL_VERSION);
+ snprintf(commandstring, STRING_SIZE, "/sbin/chroot /harddisk /sbin/mkinitrd --with=scsi_mod --with=%s --with=sd_mod --with=sr_mod --with=libata /boot/ipfirerd.img %s", driver, KERNEL_VERSION);
- snprintf(commandstring, STRING_SIZE, "/bin/chroot /harddisk /sbin/mkinitrd --with=scsi_mod --with=%s --with=sd_mod --with=sr_mod --with=libata /boot/ipfirerd-smp.img %s-smp", driver, KERNEL_VERSION);
+ snprintf(commandstring, STRING_SIZE, "/sbin/chroot /harddisk /sbin/mkinitrd --with=scsi_mod --with=%s --with=sd_mod --with=sr_mod --with=libata /boot/ipfirerd-smp.img %s-smp", driver, KERNEL_VERSION);
- snprintf(commandstring, STRING_SIZE, "/bin/chroot /harddisk /usr/bin/perl -e \"require '" CONFIG_ROOT "/lang.pl'; &Lang::BuildCacheLang\"");
+ snprintf(commandstring, STRING_SIZE, "/sbin/chroot /harddisk /usr/bin/perl -e \"require '" CONFIG_ROOT "/lang.pl'; &Lang::BuildCacheLang\"");
if (runcommandwithstatus(commandstring, ctr[TR_INSTALLING_LANG_CACHE]))
{
errorbox(ctr[TR_UNABLE_TO_INSTALL_LANG_CACHE]);
if (runcommandwithstatus(commandstring, ctr[TR_INSTALLING_LANG_CACHE]))
{
errorbox(ctr[TR_UNABLE_TO_INSTALL_LANG_CACHE]);
chmod("/harddisk/boot/grub/grubbatch", S_IXUSR | S_IRUSR | S_IXGRP | S_IRGRP | S_IXOTH | S_IROTH);
snprintf(commandstring, STRING_SIZE,
chmod("/harddisk/boot/grub/grubbatch", S_IXUSR | S_IRUSR | S_IXGRP | S_IRGRP | S_IXOTH | S_IROTH);
snprintf(commandstring, STRING_SIZE,
if (runcommandwithstatus(commandstring, ctr[TR_INSTALLING_GRUB])) {
errorbox(ctr[TR_UNABLE_TO_INSTALL_GRUB]);
goto EXIT;
if (runcommandwithstatus(commandstring, ctr[TR_INSTALLING_GRUB])) {
errorbox(ctr[TR_UNABLE_TO_INSTALL_GRUB]);
goto EXIT;
{
/* /proc is needed by the module checker. We have to mount it
* so it can be seen by setup, which is run chrooted. */
{
/* /proc is needed by the module checker. We have to mount it
* so it can be seen by setup, which is run chrooted. */
- system("/bin/swapoff /harddisk/swapfile");
- system("/sbin/umount /harddisk/var");
- system("/sbin/umount /harddisk/boot");
- system("/sbin/umount /harddisk");
+ system("/sbin/swapoff /harddisk/swapfile");
+ system("/bin/umount /harddisk/var");
+ system("/bin/umount /harddisk/boot");
+ system("/bin/umount /harddisk");