LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 05-11-2014, 11:34 AM   #1
vinipsmaker
LQ Newbie
 
Registered: May 2014
Distribution: ArchLinux
Posts: 9

Rep: Reputation: Disabled
Slackware 14.1 32bit system tarball/stage3 image/chroot image/bootstrap image


I need an image containing a Slackware installation (the root folder that contains the bin, etc, var, usr, ... folders). I've lost some hours on Google and I was unable to find such image.

Where can I find one?
 
Old 05-11-2014, 12:17 PM   #2
ruario
Senior Member
 
Registered: Jan 2011
Location: Oslo, Norway
Distribution: Slackware
Posts: 2,557

Rep: Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761
Why do you need an image? Just decide which packages you want to install and use installpkg with the --root switch to set to the location of your chroot folder.
 
Old 05-11-2014, 12:24 PM   #3
vinipsmaker
LQ Newbie
 
Registered: May 2014
Distribution: ArchLinux
Posts: 9

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by ruario View Post
Why do you need an image? Just decide which packages you want to install and use installpkg with the --root switch to set to the location of your chroot folder.
I don't have a Slackware installation. That's why I need an image... to install Slackware... inside a container.

It's the oldest distro still going on. I'm pretty confident this image must exist.
 
Old 05-11-2014, 12:41 PM   #4
ponce
LQ Guru
 
Registered: Aug 2004
Location: Pisa, Italy
Distribution: Slackware
Posts: 7,096

Rep: Reputation: 4173Reputation: 4173Reputation: 4173Reputation: 4173Reputation: 4173Reputation: 4173Reputation: 4173Reputation: 4173Reputation: 4173Reputation: 4173Reputation: 4173
sorry, inside which kind of container?

I don't think there are tarballs available with the root filesystem of a full installation for the x86/x86_64 arch (for arm there's the minirootfs)...

if you want to use installpkg on another system, you need just the pkgtools package (it's a tarball, so you can easily extract it).

Last edited by ponce; 05-11-2014 at 12:45 PM.
 
Old 05-11-2014, 12:42 PM   #5
vinipsmaker
LQ Newbie
 
Registered: May 2014
Distribution: ArchLinux
Posts: 9

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by ponce View Post
sorry, inside which kind of container?
LXC, but I can take care of the configuration myself. I just need the "filesystem tarball".
 
Old 05-11-2014, 01:24 PM   #6
ponce
LQ Guru
 
Registered: Aug 2004
Location: Pisa, Italy
Distribution: Slackware
Posts: 7,096

Rep: Reputation: 4173Reputation: 4173Reputation: 4173Reputation: 4173Reputation: 4173Reputation: 4173Reputation: 4173Reputation: 4173Reputation: 4173Reputation: 4173Reputation: 4173
here they are, 32 and 64 bit: I just created them

http://ponce.cc/slackware/lxc/
 
1 members found this post helpful.
Old 05-11-2014, 01:27 PM   #7
vinipsmaker
LQ Newbie
 
Registered: May 2014
Distribution: ArchLinux
Posts: 9

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by ponce View Post
here they are, 32 and 64 bit: I just created them

http://ponce.cc/slackware/lxc/
Thank you anon.
 
Old 05-11-2014, 01:34 PM   #8
ponce
LQ Guru
 
Registered: Aug 2004
Location: Pisa, Italy
Distribution: Slackware
Posts: 7,096

Rep: Reputation: 4173Reputation: 4173Reputation: 4173Reputation: 4173Reputation: 4173Reputation: 4173Reputation: 4173Reputation: 4173Reputation: 4173Reputation: 4173Reputation: 4173
np.

if you want to assemble them yourself or, for any reason, you need more infos about lxc on Slackware, you can refer to

https://slackware.ponce.cc/blog/2012...lackware-14-0/
https://slackware.ponce.cc/blog/2014...4-14-1current/
http://www.vislab.uq.edu.au/howto/lxc/lxc.html
 
1 members found this post helpful.
Old 05-11-2014, 01:51 PM   #9
vinipsmaker
LQ Newbie
 
Registered: May 2014
Distribution: ArchLinux
Posts: 9

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by ponce View Post
here they are, 32 and 64 bit: I just created them

http://ponce.cc/slackware/lxc/
I just noticed you container is minimal, which is fine, but doesn't come with the standard Slackware tools (such as installpkg, removepkg, upgradepkg, makepkg, explodepkg, pkgtool), which makes me doubt if I can refer to this container as a Slackware container.

Anyway, I'll hunt the required packages and extract them. Thanks for the help so far. I think I can manage from here.
 
Old 05-11-2014, 01:52 PM   #10
ruario
Senior Member
 
Registered: Jan 2011
Location: Oslo, Norway
Distribution: Slackware
Posts: 2,557

Rep: Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761
Quote:
Originally Posted by ponce View Post
if you want to use installpkg on another system, you need just the pkgtools package (it's a tarball, so you can easily extract it).
To expand on that for the benefit of the OP or others reading this, just fetch the installpkg script. Make it executable and use it to install your selected Slackware packages from your host system using an appropriate --root option. You will get a warning about using a non tar version 1.13 version. This is indeed not ideal but it should be good enough for purposes like setting up a chroot/LXC. Non 1.13 tar is more of an issue for removepkg and makepkg.

If you want you could remove the -U and -l options from the tar extraction in installpkg, as their meanings have changed in later versions of tar. Here is a patch:

Code:
--- installpkg.orig
+++ installpkg
@@ -93,22 +93,7 @@
 
 # So that we know what to expect...
 umask 022
-TAR=tar-1.13
-$TAR --help 1> /dev/null 2> /dev/null
-if [ ! $? = 0 ]; then
-  TAR=tar
-fi
-if [ ! "$(LC_MESSAGES=C $TAR --version)" = "tar (GNU tar) 1.13
-
-Copyright (C) 1988, 92,93,94,95,96,97,98, 1999 Free Software Foundation, Inc.
-This is free software; see the source for copying conditions.  There is NO
-warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
-
-Written by John Gilmore and Jay Fenlason." ]; then
-  echo "WARNING: pkgtools are unstable with tar > 1.13."
-  echo "         You should provide a \"tar-1.13\" in your \$PATH."
-  sleep 5
-fi
+TAR=tar
 
 usage() {
  cat << EOF
@@ -519,7 +504,7 @@
     cat $DESCRIPTION | grep "^$shortname:" >> $ADM_DIR/packages/$shortname 2> /dev/null
   fi
   echo "FILE LIST:" >> $ADM_DIR/packages/$shortname
-  ( cd $ROOT/ ; $packagecompression -dc | $TAR -xlUpvf - ) < $package >> $TMP/$shortname 2> /dev/null
+  ( cd $ROOT/ ; $packagecompression -dc | $TAR -xpvf - ) < $package >> $TMP/$shortname 2> /dev/null
   if [ "$(cat $TMP/$shortname | grep '^\./' | wc -l | tr -d ' ')" = "1" ]; then
     # Good.  We have a package that meets the Slackware spec.
     cat $TMP/$shortname >> $ADM_DIR/packages/$shortname
Save the above as installpkg.patch in the directory where you saved installpkg and issue the following command:

Code:
patch < installpkg.patch
If you are interested to find out more about why Slackware uses GNU tar 1.13, read this. This more recent post might also be interesting.
 
Old 05-11-2014, 01:55 PM   #11
ruario
Senior Member
 
Registered: Jan 2011
Location: Oslo, Norway
Distribution: Slackware
Posts: 2,557

Rep: Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761
Quote:
Originally Posted by vinipsmaker View Post
doesn't come with the standard Slackware tools (such as installpkg, removepkg, upgradepkg, makepkg, explodepkg, pkgtool), which makes me doubt if I can refer to this container as a Slackware container.

Anyway, I'll hunt the required packages and extract them. Thanks for the help so far. I think I can manage from here.
You can get these here. Install it with installpkg from your host system, as explained in my previous post, or from within the lxc.

Last edited by ruario; 05-11-2014 at 01:56 PM.
 
Old 05-11-2014, 01:58 PM   #12
ponce
LQ Guru
 
Registered: Aug 2004
Location: Pisa, Italy
Distribution: Slackware
Posts: 7,096

Rep: Reputation: 4173Reputation: 4173Reputation: 4173Reputation: 4173Reputation: 4173Reputation: 4173Reputation: 4173Reputation: 4173Reputation: 4173Reputation: 4173Reputation: 4173
Quote:
Originally Posted by vinipsmaker View Post
I just noticed you container is minimal, which is fine, but doesn't come with the standard Slackware tools (such as installpkg, removepkg, upgradepkg, makepkg, explodepkg, pkgtool), which makes me doubt if I can refer to this container as a Slackware container.

Anyway, I'll hunt the required packages and extract them. Thanks for the help so far. I think I can manage from here.
I don't know where you're actually looking for them, but all the commands you cited are in the /sbin directory of the container filesystem.
Code:
$ ls -la /var/lib/lxc/slack32/rootfs/var/log/packages/pkgtools-14.1-noarch-2 
-rw-r--r-- 1 root root 1331 May 11 20:16 /var/lib/lxc/slack32/rootfs/var/log/packages/pkgtools-14.1-noarch-2
$ ls -la /var/lib/lxc/slack32/rootfs/sbin/ | grep pkg 
-rwxr-xr-x  1 root root   3169 May 11  2010 explodepkg
-rwxr-xr-x  1 root root  20490 Apr 22  2011 installpkg
-rwxr-xr-x  1 root root  11315 Jun  2  2009 makepkg
-rwxr-xr-x  1 root root  22670 Oct  3  2013 pkgtool
-rwxr-xr-x  1 root root  14048 Apr 28  2009 removepkg
-rwxr-xr-x  1 root root  12135 May 11  2010 upgradepkg

Last edited by ponce; 05-11-2014 at 02:04 PM.
 
1 members found this post helpful.
Old 05-11-2014, 02:03 PM   #13
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-15.0
Posts: 11,055

Rep: Reputation: Disabled
Quote:
Originally Posted by ruario View Post
If you are interested to find out more about why Slackware uses GNU tar 1.13, read this. This more recent post might also be interesting.
I just noticed that in Slackware-current's installer, two versions of tar are shipped:
Code:
/tmp$ ls -l initrd-Slackware-current/bin/tar*
-rwxr-xr-x 1 didier users 269332 avril 14  2011 initrd-Slackware-current/bin/tar
-rwxr-xr-x 1 didier users 122396 avril 14  2011 initrd-Slackware-current/bin/tar-1.13
lrwxrwxrwx 1 didier users      3 mai   11 11:28 initrd-Slackware-current/bin/tar-1.26 -> tar
/tmp
As a reminder, in Slackware 14.1's installer instead:
Code:
/tmp$ ls -l initrd-Slackware-14.1/bin/tar*
lrwxrwxrwx 1 didier users      8 mai   11 11:28 initrd-Slackware-14.1/bin/tar -> tar-1.13
-rwxr-xr-x 1 didier users 122396 avril 14  2011 initrd-Slackware-14.1/bin/tar-1.13
/tmp$
I don't know why Pat made this change, but he certainly knows
 
Old 05-11-2014, 02:05 PM   #14
vinipsmaker
LQ Newbie
 
Registered: May 2014
Distribution: ArchLinux
Posts: 9

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by ponce View Post
I don't know where you're actually looking for them, but all the commands you cited are in the /sbin directory of the container filesystem.
Code:
$ ls -la /var/lib/lxc/slack32/rootfs/var/log/packages/pkgtools-14.1-noarch-2 
-rw-r--r-- 1 root root 1331 May 11 20:16 /var/lib/lxc/slack32/rootfs/var/log/packages/pkgtools-14.1-noarch-2
$ ls -la /var/lib/lxc/slack32/rootfs/sbin/ | grep pkg 
-rwxr-xr-x  1 root root   3169 May 11  2010 explodepkg
-rwxr-xr-x  1 root root  20490 Apr 22  2011 installpkg
-rwxr-xr-x  1 root root  11315 Jun  2  2009 makepkg
-rwxr-xr-x  1 root root  22670 Oct  3  2013 pkgtool
-rwxr-xr-x  1 root root  14048 Apr 28  2009 removepkg
-rwxr-xr-x  1 root root  12135 May 11  2010 upgradepkg
I found them.

Looks like it's a problem of lxc-attach vs lxc-console. lxc-attach won't update the PATH env var. I'll use lxc-console from now on.

Thanks again.
 
Old 05-11-2014, 02:08 PM   #15
ruario
Senior Member
 
Registered: Jan 2011
Location: Oslo, Norway
Distribution: Slackware
Posts: 2,557

Rep: Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761
Quote:
Originally Posted by Didier Spaier View Post
As a reminder, in Slackware 14.1's installer instead:
Code:
/tmp$ ls -l initrd-Slackware-14.1/bin/tar*
lrwxrwxrwx 1 didier users      8 mai   11 11:28 initrd-Slackware-14.1/bin/tar -> tar-1.13
-rwxr-xr-x 1 didier users 122396 avril 14  2011 initrd-Slackware-14.1/bin/tar-1.13
/tmp$
I don't know why Pat made this change, but he certainly knows
Stuart also knows.

Quote:
Originally Posted by drmozes View Post
It appears that it was my idea to wipe out the latest version of tar and symlink tar-1.13 to tar anyway (seemed optimal and efficient 6 years ago! ;-) ). I've added it to my installer to do list - Pat will most likely accept this change as it's non intrusive - although you'll only know if it appears ;-)
 
  


Reply



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
Unable to build bootstrap image on OpenEmbedded naveen_chandran Linux - Embedded & Single-board computer 0 04-15-2009 04:25 AM
LXer: Graphics on Linux: Eight great image image resources and tools LXer Syndicated Linux News 0 04-08-2009 08:11 PM
clonezilla clone disk to image, when restore from image to destination hdd problem. hocheetiong Linux - Newbie 3 05-06-2008 07:59 PM
PHP: how can I return an image - not the html img src tag, but the image data BrianK Programming 3 05-18-2007 02:28 PM
LXer: Creating a dd/dcfldd Image Using Automated Image & Restore (AIR) LXer Syndicated Linux News 0 03-07-2007 05:16 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 01:54 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