LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (http://www.linuxquestions.org/questions/slackware-14/)
-   -   Slack 14.1 USB install (http://www.linuxquestions.org/questions/slackware-14/slack-14-1-usb-install-4175493549/)

SAJM 02-03-2014 08:49 AM

Slack 14.1 USB install
 
Hi there

I have an XP laptop with Slackware 14.1 iso downloaded on it.
I have created a 500M bootable usb stick.
I have booted a Dell inspiron 1520 laptop with the USB stick, created the drives and am now up to select source media. This is where it goes wrong. I cannot FTP or telnet to my xp laptop. tftp does not seem to work. I cannot make head nor tail of NFS.

I thought I might be able to telnet or FTP into the new Dell laptop from my xp laptop to copy the linux files onto a drive there but access is denied in both directions.

I'm at the end of my knowledge and cannot get any further.

I know a CD or larger USB stick would work but I have neither.

Didier Spaier 02-03-2014 09:22 AM

Hi SAJM, welcome to LQ.

If you have an ethernet cable that can link both machines, easiest way is booting the USB installer on the XP laptop, then instead of running "setup" run "pxesetup". The installer will help you make of the XP laptop a PXE server (not changing anything on it besides that). When it'll be running, just wire link both laptops and start the Dell inspiron. You'll be greeted by Slackware installer that will allow you to download the packages from the XP laptop.

Of course, first set the BIOS of the Dell inspiron to PXE booting.

SAJM 02-03-2014 02:32 PM

Quote:

Originally Posted by Didier Spaier (Post 5110382)
Hi SAJM, welcome to LQ.

If you have an ethernet cable that can link both machines, easiest way is booting the USB installer on the XP laptop, then instead of running "setup" run "pxesetup". The installer will help you make of the XP laptop a PXE server (not changing anything on it besides that). When it'll be running, just wire link both laptops and start the Dell inspiron. You'll be greeted by Slackware installer that will allow you to download the packages from the XP laptop.

Of course, first set the BIOS of the Dell inspiron to PXE booting.


Thanks for the reply.

I tried what you suggested. I could mount the C: drive from my XP laptop OK as an ntfs sda device. I did an "ls" and see the contents of the c: drive but I could not get the PXEsetup to recognise the directory where slack was. It kept saying there was no kernel there. The directory in question is an iso download from a slackware recommended torrent. No reason to suspect it is incomplete or corrupted.

Didier Spaier 02-03-2014 04:08 PM

Quote:

Originally Posted by SAJM (Post 5110655)
I did an "ls" and see the contents of the c: drive but I could not get the PXEsetup to recognise the directory where slack was. It kept saying there was no kernel there. The directory in question is an iso download from a slackware recommended torrent. No reason to suspect it is incomplete or corrupted.

That looks a bit strange. Once logged in the installer you should make two mount points, one for the NTFS partition and one for the ISO, mount the NTFS partition, then the ISO. e.g.:
Code:

mkdir /XP
mkdir /ISO
mount /dev/sda1 /XP # you can check partition's name with cfdisk first
mount /XP/path/to/the/ISO /ISO

Then run pxesetup and choose as SOURCE a pre-mounted directory, that will be either /ISO/slackware or /ISO/slackware64 depending if you downloaded slackware-14.1 or slackware64-14.1.

SAJM 02-03-2014 06:32 PM

Quote:

Originally Posted by Didier Spaier (Post 5110740)
That looks a bit strange. Once logged in the installer you should make two mount points, one for the NTFS partition and one for the ISO, mount the NTFS partition, then the ISO. e.g.:
Code:

mkdir /XP
mkdir /ISO
mount /dev/sda1 /XP # you can check partition's name with cfdisk first
mount /XP/path/to/the/ISO /ISO

Then run pxesetup and choose as SOURCE a pre-mounted directory, that will be either /ISO/slackware or /ISO/slackware64 depending if you downloaded slackware-14.1 or slackware64-14.1.

I've done all that, the PXE runs on my XP laptop and the Del laptop boots up on the XP laptop but it cannot find the kernel. I have noticed that PXEsetup says it will work on Linux or FAT partitions, it makes no reference to NTFS. PXEsetup will simply not recognise the "slack" directory on my c: drive. I guess I'm snookered!

Didier Spaier 02-03-2014 11:56 PM

Quote:

Originally Posted by SAJM (Post 5110836)
PXEsetup will simply not recognise the "slack" directory on my c: drive

??? It shouldn't have to, as the ISO is mounted in a RAM filesystem (provided you choose as SOURCE a pre-mounted directory as indicated in my previous post, not a hard drive partition).

SAJM 02-04-2014 12:19 PM

Quote:

Originally Posted by Didier Spaier (Post 5110740)
mkdir /XP
mkdir /ISO
mount /dev/sda1 /XP # you can check partition's name with cfdisk first
mount /XP/path/to/the/ISO /ISO

I don't get it, I just don't get it.

Let's go back to the beginning.

I have an xp laptop with slack 14.1 in a directory "slackware" on the C: drive

I load the xp laptop with linux from a usb stick.

On that machine I create 2 directories.

mkdir xp
mkdir slack

Then I mount -t ntfs /dev/sda2 xp

If I change to the xp directory and do ls I can see the contents, including slackware.

Now if I try mount /xp/slackware slack or mount /dev/sda2/slackware slack or any similar combination I get "not a block device"

Surly the kernel should be coming from the usb stick not the iso package which presumably has to be unpacked first.

I am guessing that my depth of knowledge is just not up to it. Am I wasting my time here?

Didier Spaier 02-04-2014 02:47 PM

Quote:

Originally Posted by SAJM (Post 5111385)
Let's go back to the beginning.

Yes, let's do that.

Theory

C: represents a partition on the hard disk of your xp laptop.

Under Linux the same hard disk partition is named instead /dev/sda1 or /dev/sda2 for instance.

Now, when you launch the installer, at first it doesn't make use of your hard disk at all. Basically, what it does is:
  1. Create a file system in Random Access Memory or RAM (that is called for that reason an initramfs), and put in it all that's necessary to perform the installation (a kernel + modules, programs and files).
  2. Allow you to start the installation process running setup.
  3. Set the target hard disk partition (where the new Linux system will be installed).
  4. Ask for the source (where are the packages to be installed).
  5. Install the packages.
  6. Configure the new system.
Now if instead of setup you type pxesetup at step #2, the installer does what follows instead of steps # 3 through 6:
  • Set up on the first computer a PXE server, i.e. a server able to provide to another computer what it needs to boot (and possibly, as in our case, run an installer).
  • Check that the server has all it will need to provide to the other computer, in order for this other computer to perform the installation: the installer itself, a kernel and packages.
  • Start the PXE server, that is then able to answer requests from the other computer(s).
Please note that all that is done in RAM, nothing is modified in the first computer's hard disk.

Now, let's link both computers with an Ethernet cable and do what follows on the second computer:
  • Set up the BIOS so that the computer will first try to make a PXE (or network) boot.
  • (restart) the second computer: that will send a request to the first computer to provide what the second needs to boot.
  • The first computer (the XP laptop in your case) will the send the installer + the kernel and modules.
  • The second computer will then boot from that installer and then go through steps #2 through #6 already described. At step #5 the first computer will send the packages to be installed.

Practice

Do this:
  • Plug in the Slackware USB installer on the xp laptop.
  • Switch this laptop on.
  • When asked by the installer, login as "root".
  • Then type following commands (please note that you are actually making the directories and mounting the devices in RAM, not on the hard disk)
Code:

fdisk -l # To check what is the name of C: under Linux
mkdir  /XP
mkdir  /ISO
mount /dev/sda1  /XP # If C: is not /dev/sda1, adapt accordingly
# Check where is the DVD ISO file swith "ls /XP"
mount /XP/path/to/the/ISO  /ISO

  • Type pxesetup
  • When asked, choose as SOURCE a pre-mounted directory, that will be either /ISO/slackware or /ISO/slackware64 depending if you downloaded slackware-14.1 or slackware64-14.1.
  • Start the PXE server.
  • Link the two computers with an Ethernet cable.
  • If not already done set the BIOS of the second computer to try first PXE booting.
  • (Re)start the second computer.You should then see the greeting screen of the installer.
  • Proceed to installation on the second computer.

SAJM 02-04-2014 07:45 PM

Quote:

Originally Posted by Didier Spaier (Post 5111482)
Yes, let's do that.

Theory

C: represents a partition on the hard disk of your xp laptop.

Under Linux the same hard disk partition is named instead /dev/sda1 or /dev/sda2 for instance.

Now, when you launch the installer, at first it doesn't make use of your hard disk at all. Basically, what it does is:
  1. Create a file system in Random Access Memory or RAM (that is called for that reason an initramfs), and put in it all that's necessary to perform the installation (a kernel + modules, programs and files).
  2. Allow you to start the installation process running setup.
  3. Set the target hard disk partition (where the new Linux system will be installed).
  4. Ask for the source (where are the packages to be installed).
  5. Install the packages.
  6. Configure the new system.
Now if instead of setup you type pxesetup at step #2, the installer does what follows instead of steps # 3 through 6:
  • Set up on the first computer a PXE server, i.e. a server able to provide to another computer what it needs to boot (and possibly, as in our case, run an installer).
  • Check that the server has all it will need to provide to the other computer, in order for this other computer to perform the installation: the installer itself, a kernel and packages.
  • Start the PXE server, that is then able to answer requests from the other computer(s).
Please note that all that is done in RAM, nothing is modified in the first computer's hard disk.

Now, let's link both computers with an Ethernet cable and do what follows on the second computer:
  • Set up the BIOS so that the computer will first try to make a PXE (or network) boot.
  • (restart) the second computer: that will send a request to the first computer to provide what the second needs to boot.
  • The first computer (the XP laptop in your case) will the send the installer + the kernel and modules.
  • The second computer will then boot from that installer and then go through steps #2 through #6 already described. At step #5 the first computer will send the packages to be installed.

Practice

Do this:
  • Plug in the Slackware USB installer on the xp laptop.
  • Switch this laptop on.
  • When asked by the installer, login as "root".
  • Then type following commands (please note that you are actually making the directories and mounting the devices in RAM, not on the hard disk)
Code:

fdisk -l # To check what is the name of C: under Linux
mkdir  /XP
mkdir  /ISO
mount /dev/sda1  /XP # If C: is not /dev/sda1, adapt accordingly
# Check where is the DVD ISO file swith "ls /XP"
mount /XP/path/to/the/ISO  /ISO

  • Type pxesetup
  • When asked, choose as SOURCE a pre-mounted directory, that will be either /ISO/slackware or /ISO/slackware64 depending if you downloaded slackware-14.1 or slackware64-14.1.
  • Start the PXE server.
  • Link the two computers with an Ethernet cable.
  • If not already done set the BIOS of the second computer to try first PXE booting.
  • (Re)start the second computer.You should then see the greeting screen of the installer.
  • Proceed to installation on the second computer.

Well I must have tried a thousand combinations of the above. I cannot mount the slackware directory because of the errors I listed in an earlier post. In the end I ignored the error messages and let the TFTP server run anyway. It connected to the laptop and loaded pxelinux.cfg. At the boot: prompt it gave the error

"could not find kernel image: kernels/huge.s/bzImage

linuxtinker 02-06-2014 10:40 AM

I am not sure how you created the Bootable Stick but If the stick has enough room you can copy the slackware tree to the stick. I did an install yesterday from a usb stick . I followed http://alien.slackbook.org/blog/inst...b-thumb-drive/ and then used an archive manager, that can read .ISO , to put the slackware install files into the usb itself .

SAJM 02-06-2014 12:09 PM

Quote:

Originally Posted by linuxtinker (Post 5112793)
I am not sure how you created the Bootable Stick but If the stick has enough room you can copy the slackware tree to the stick. I did an install yesterday from a usb stick . I followed http://alien.slackbook.org/blog/inst...b-thumb-drive/ and then used an archive manager, that can read .ISO , to put the slackware install files into the usb itself .

The problem is the usbstick is too small. I can load linux setup OK but cannot access my XP laptop that contains the Linux ISO files.

linuxtinker 02-06-2014 12:55 PM

I used a 2gb stick, I didnt include the src files and left out the KDI and KDE Stuff . I was able to add them later after I did the initial install. You can also look into installing SalixOS and then converting it to a true slackware install. There was a thread already posted on how to do that.

SAJM 02-06-2014 04:51 PM

Quote:

Originally Posted by linuxtinker (Post 5112867)
I used a 2gb stick, I didnt include the src files and left out the KDI and KDE Stuff . I was able to add them later after I did the initial install. You can also look into installing SalixOS and then converting it to a true slackware install. There was a thread already posted on how to do that.

Salix Ratpoison may just fit on my USB stick. I'll give it a go.

linuxtinker 02-06-2014 11:03 PM

Here is a link to covert it to Slackware http://straightedgelinux.com/blog/howto/salix.html

Didier Spaier 02-07-2014 07:29 AM

I've cooked a mini iso that can be used to make an USB installer. It includes only packages series a, ap and n so its size is less than 400 mega bytes. Do this:
Code:

wget http://slint.fr/testing/slint-14.1-dvd.iso
wget http://slint.fr/testing/slint-14.1-dvd.iso.md5
md5sum -c http://slint.fr/testing/slint-14.1-dvd.iso.md5 #answer should be "OK"
# now, plug-in you USB stick (512MB is enough)
# check the name of the USB device.
cat /proc/partitions # I'll assume device name is /dev/sdb, but avoid wiping out a hard disk with following command, so...
# CHECK THE NAME and adapt accordingly. YOU HAVE BEEN WARNED.
su # we need to be root now
dd if=slint-14.1-dvd.iso of=/dev/sdb bs=1M

Now, boot off the USB stick to install Slackware on the other computer ("full" install, that will only include packages series a, ap and n) and reboot. During installation, for your network setting, choose Static IP or DHCP as you don't have the packages needed by NetworkManager yet.Then as root do this:
Code:

# You'll need this package from the l series because slackpkg uses awk, that needs it:
wget http://mirrors.slackware.com/slackware/slackware-14.1/slackware/l/mpfr-3.1.2-i486-1.txz
installpkg mpfr-3.1.2-i486-1.txz
nano /etc/slackpkg mirrors
# uncomment one (good) mirror for slackware-14.1 and exit
nano /etc/blacklist
# include what you don't want, e.g. kdei and exit
slackpkg update gpg
slackpkg update
slackpkg install slackware

You should then have a full Slackware-14.1, minus the packages or series of which you wrote the names in /etc/slackpkg/blacklist.


All times are GMT -5. The time now is 10:16 AM.