SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I received my pi two days ago. Ran with debian image the first day and found it a slow boot with some issues I didn't stick around long enough to figure out. After apt-get updates and loads of sudos I had wired network up and ran LXDE but it wasn't as responsive as I would have liked. The next day I ran the arch image. Very fast boot. I got wireless up and pacman'ed what I was supposed to need for LXDE but never got it up and running.
Today a downloaded the above image ponce pointed out above and ran it on my pi. What a difference! The default wm is XFCE but it was much better than the debian experience. Add a user, run netconfig then /etc/rc.d/rc.inet1 eth0 and I have a wired connection. Edit /etc/inittab to run level 4 and Bob's your uncle. I'm home.
Much better graphics out of the box with full resolution on a 20" monitor. No black framed 800 X 600 as was the case with debian.
Last edited by justwantin; 06-07-2012 at 04:30 AM.
1 members found this post helpful.
Click here to see the post LQ members have rated as the most helpful post in this thread.
distcc is very nice, I've often used it with Gentoo. But since you will need a toolchain anyway when using distcc, I'd consider to crosscompile the packages for armedslack.
Markus
The build script for armedslack-current's distcc toolchain is on the FTP site.
You just need to build it and then you can use distcc on the ARM machines.
There's a Slackware ARM Installer image, up to date kernel and boot packages, a package that hacks fixes for several annoying problems, some patches for xorg on -current, and XFCE 4.10
The new kernels and boot firmware are a big improvement.
I "expressed an interest" in Raspberry Pi ages ago (can't remember exactly when), and have heard nothing since. It might be that they're picky about email addresses. From: http://uk.rs-online.com/web/generalD..._--_-questions
Quote:
Q - I do not seem to be receiving email updates from you
A - Generic email addresses such as admin@ or sales@ may have filters that could prevent you from receiving our emails. If you are about to register please use a non-generic email address such as name.name@. If you have already registered your interest in Raspberry Pi but you have not received any email from us, this could be the reason. In order to change your registration email address please contact us at raspberrypi@rswww.com highlighting your full name and also the original email address you used to register, as well as your new email address. Please note email addresses cannot be amended once an order has been placed.
My email address isn't admin or sales@, though. I'm not desperate, anyway. Probably **** it up, like I've done with my SheevaPlug.
I'm trying to create a script for generating a armedslack image for the raspberry pi, it looks like everything is correct and it should boot but it doesn't. On screen only the cursor keeps blinking.
Code:
#!/bin/bash
if [ $EUID -ne 0 ]; then
echo "you need to be root"
exit 1
fi
slack_release="current"
# always in megabytes
bootsize="64M"
rootsize="3776M"
swapsize="256M"
# these 3 sizes must add up to imagesize
imagesize="4096M"
splitGPUMEM="224" # 128 (for headless server of low grahical uses) or 192 (medium graphical use) or 224(video watching, ...)
kernelparams="dwc_otg.lpm_enable=0 console=ttyAMA0,115200 kgdboc=ttyAMA0,115200 root=/dev/mmcblk0p2 rootfstype=ext4 rootwait"
newhostname="armslackPI"
newrootpassword="pi"
keylayout="us"
imagesizeMB=`expr "$imagesize" : '\([[:digit:]]*\)'`
bootsizeMB=`expr "$bootsize" : '\([[:digit:]]*\)'`
rootsizeMB=`expr "$rootsize" : '\([[:digit:]]*\)'`
swapsizeMB=`expr "$swapsize" : '\([[:digit:]]*\)'`
buildenv="./pi"
rootfs="${buildenv}/root"
bootfs="${rootfs}/boot"
creationdate=`date +%Y%m%d`
cleanup ()
{
echo "cleaning up"
umount $bootp > /dev/null 2> /dev/null
umount $rootp > /dev/null 2> /dev/null
losetup -d $bootp > /dev/null 2> /dev/null
losetup -d $rootp > /dev/null 2> /dev/null
losetup -d $swapp > /dev/null 2> /dev/null
}
cleanupfailure ()
{
cleanup
echo failure
exit 1
}
echo "creating image"
mkdir -p $buildenv || cleanupfailure
image="${buildenv}/rpi_armedslack_${slack_release}_${mydate}.img"
rm $image 2> /dev/null
dd if=/dev/zero of=$image bs=1MB count=$imagesizeMB || cleanupfailure
echo "$image created"
fdisk $image << EOF
n
p
1
+$bootsize
t
c
n
p
2
+$rootsize
t
2
83
n
p
3
+$swapsize
t
3
82
w
EOF
echo "written partition table"
echo "setting loopdevices for the partitions"
offset=$(( 2048 * 512))
sizelimit=$(( $bootsizeMB * 1024 * 1024))
bootp=`losetup --offset $offset --sizelimit $sizelimit --show -f $image`
offset=$(( $offset + sizelimit))
sizelimit=$(( $rootsizeMB * 1024 * 1024))
rootp=`losetup --offset $offset --sizelimit $sizelimit --show -f $image`
offset=$(( $offset + sizelimit))
sizelimit=$(( $swapsizeMB * 1024 * 1024))
swapp=`losetup --offset $offset --sizelimit $sizelimit --show -f $image`
echo "creating filesystems"
mkfs.vfat $bootp || cleanupfailure
mkfs.ext4 $rootp || cleanupfailure
mkswap $swapp || cleanupfailure
echo "setting up root fs"
tempcurrentdir=`pwd`
mkdir -p $rootfs
echo "mounting root $rootp on $rootfs"
mount $rootp $rootfs || cleanupfailure
# getting the armslack packages, using rsync
echo "retrieving/updating armedslack"
rsync -Pavv --exclude=source --delete ftp.armedslack.org::armedslack/armedslack-${slack_release} . > /dev/null
if [ ! -d armedslack-${slack_release}/slackware ]; then
echo "Unable to find slackware package directory"
cleanupfailure
fi
# all package sets
PKGSETLIST="a \
ap \
l \
n \
x \
xap
"
# all seperate packages
#packages from extra must be relative against armedslack/slackware directory, examples; y/bsd-games ../extra/bittornado/bittornado
PKGLIST="../extra/bittorrent/bittorrent \
"
rootfs=`cd $rootfs; pwd` # make absolute
echo "installing packages in $rootfs"
for PKGL in $PKGSETLIST ; do
pushd armedslack-${slack_release}/slackware > /dev/null
installpkg -root $rootfs $PKGL/*.t?z || cleanupfailure
popd > /dev/null
done
for PKG in $PKGLIST ; do
pushd armedslack-${slack_release}/slackware > /dev/null
installpkg -root $rootfs $PKG*.t?z || cleanupfailure
popd > /dev/null
done
echo "configuring the installation in $rootfs"
cat << EOF >> etc/ld.so.conf
/lib
/usr/lib
EOF
ldconfig -r $rootfs
# Create fstab
cat << EOF > $rootfs/etc/fstab
#
# Sample /etc/fstab
#
#
# <file system> <mount point> <type> <options> <dump> <pass>
proc /proc proc defaults 0 0
#
# tmpfs /dev/shm tmpfs defaults 0 0
#
/dev/mmcblk0p1 /boot fat errors=remount-ro 0 0
/dev/mmcblk0p3 none swap sw 0 0
/dev/mmcblk0p2 / ext4 errors=remount-ro 0 1
EOF
chmod +x $rootfs/etc/rc.d/rc.{ssh*,rpc}
cat << EOF > $rootfs/etc/rc.d/rc.keymap
#!/bin/sh
# Load the keyboard map. More maps are in /usr/share/kbd/keymaps.
if [ -x /usr/bin/loadkeys ]; then
/usr/bin/loadkeys $keylayout.map
fi
EOF
chmod 755 $rootfs/etc/rc.d/rc.keymap
echo $newhostname > etc/HOSTNAME
if [ -d $rootfs/usr/share/fonts/ ]; then
( cd $rootfs/usr/share/fonts/
find . -type d -mindepth 1 -maxdepth 1 | while read dir ; do
( cd $dir
mkfontscale .
mkfontdir . )
done
/usr/bin/fc-cache -f )
fi
if [ -d $rootfs/etc/X11/xinit/ ]; then
( cd $rootfs/etc/X11/xinit/
ln -vfs xinitrc.wmaker xinitrc )
fi
cat << EOF > $rootfs/tmp/setrootpw
/usr/bin/echo "root:$ROOTPASS" | /usr/sbin/chpasswd
EOF
chmod 755 $rootfs/tmp/setrootpw
chroot $rootfs /tmp/setrootpw
rm -f $rootfs/tmp/setrootpw
sed -i 's?USE_DHCP\[0\]=.*?USE_DHCP\[0\]="yes"?g' $rootfs/etc/rc.d/rc.inet1.conf
cat << EOF > $rootfs/etc/e2fsck.conf
# These options stop e2fsck from erroring/requiring manual intervention
# when it encounters bad time stamps on filesystems -- which happens on
# the Versatile platform because QEMU does not have RTC (real time clock)
# support.
#
[options]
accept_time_fudge = 1
broken_system_clock = 1
EOF
echo "vchiq
snd_bcm2835
" >> $rootfs/etc/modules
rm -r $rootfs/boot/*
rm -r $rootfs/lib/modules/*
#setup boot fs
echo "setting up boot fs"
mkdir -p $bootfs
echo "mounting boot $bootp on $bootfs"
mount $bootp $bootfs || cleanupfailure
# download the latest firmwares/kernel
firmware=$buildenv/firmware
if [ -d "$firmware/.git" ]; then
tempcurrentdir=`pwd`
cd $firmware
git pull || cleanupfailure
cd $tempcurrentdir
else
git clone git://github.com/Hexxeh/rpi-firmware.git $firmware || cleanupfailure
fi
#copy all to boot dir except the .git stuff
targetdir=`cd $bootfs; pwd`
tempcurrentdir=`pwd`
# cd $firmware
# find . -type f | grep -iv .git | xargs -r -I TT cp -r --parents TT $targetdir || cleanupfailure
# cd $tempcurrentdir
cp $firmware/* $targetdir # || cleanupfailure
# decide which start.elf to use
cp $bootfs/arm${splitGPUMEM}_start.elf $bootfs/start.elf || cleanupfailure
echo $kernelparams > $bootfs/cmdline.txt
echo "boot fs done"
echo "installing kernel modules"
mkdir $rootfs/lib
cp -r $firmware/modules $rootfs/lib
echo "copying vc"
mkdir $rootfs/opt
cp -r $firmware/vc $rootfs/opt
cleanup
echo "succes; created image in $image now use dd command to put it on an sd"
can somebody give me some pointers what needs to change to make it bootable?
I'm trying to create a script for generating a armedslack image for the raspberry pi, it looks like everything is correct and it should boot but it doesn't. On screen only the cursor keeps blinking.
can somebody give me some pointers what needs to change to make it bootable?
I don't know if the following pointers solve everything, but here goes:
'bs=1MB' in the dd command means 1*1000*1000, not 1*1024*1024. Therefore the image is smaller than you think. You need to use 'bs=1M'.
Code:
fdisk $image << EOF
n
p
1
[...]
w
EOF
You need to allow for the partition table overhead before partition 1. You can see the error messages when the script is run:
Code:
Partition number (1-4, default 3): First sector (7866368-7999999, default 7866368): Using default value 7866368
Last sector, +sectors or +size{K,M,G} (7866368-7999999, default 7999999): Value out of range.
Last sector, +sectors or +size{K,M,G} (7866368-7999999, default 7999999): Last sector, +sectors or +size{K,M,G} (7866368-7999999, default 7999999): Value out of range.
Last sector, +sectors or +size{K,M,G} (7866368-7999999, default 7999999): Value out of range.
Last sector, +sectors or +size{K,M,G} (7866368-7999999, default 7999999): Using default value 7999999
Best fix would be to calculate a smaller swapsize instead of setting it as a constant:
splitGPUMEM="224" # 128 (for headless server of low grahical uses) or 192 (medium graphical use) or 224(video watching, ...)
arm192_start.elf gives 192 to Linux and 64 to the GPU, arm224_start.elf gives 224 to Linux and 32 to the GPU, so the comment is the wrong way round ;-)
Slackware prefers the root filesystem to be read-only until it's remounted, so add 'ro' at the end. If you're not using the serial output, change 'console=ttyAMA0,115200 kgdboc=ttyAMA0,115200' to 'console=tty1', like this:
But you have some good ideas in there too. In particular, the e2fsck.conf idea is great and I'll probably steal it! Thanks!
Edit: Damn, I forgot to mention, the ARMedslack devs package doesn't include device nodes for /dev/mmcblk*, and that might be another problem. Create the nodes like this:
Code:
mknod -m 660 $rootfs/dev/mmcblk0 b 179 0
mknod -m 660 $rootfs/dev/mmcblk0p1 b 179 1
mknod -m 660 $rootfs/dev/mmcblk0p2 b 179 2
mknod -m 660 $rootfs/dev/mmcblk0p3 b 179 3
chown root:disk $rootfs/dev/mmcblk*
Another Edit: Someone else (way above my brain level) reminds me that udev is active from very early in the boot, so the static device nodes are unlikely to be important
Last edited by 55020; 07-02-2012 at 01:43 PM.
Reason: device nodes
There's a Slackware ARM Installer image, up to date kernel and boot packages, a package that hacks fixes for several annoying problems, some patches for xorg on -current, and XFCE 4.10
The new kernels and boot firmware are a big improvement.
I hope it all works properly. If it does, Enjoy
while i wait for a raspi, i am using qemu to "get accquainted" ..... any way to load the armedslack image into qemu? i don't have enough experience with qemu to "automagically" get the command line right.....
Last edited by unclejed613; 07-02-2012 at 10:28 PM.
while i wait for a raspi, i am using qemu to "get accquainted" ..... any way to load the armedslack image into qemu? i don't have enough experience with qemu to "automagically" get the command line right.....
You can't run the Raspberry Pi boot images on qemu -- qemu is more like a different arm machine in its own right, with different 'hardware' than the Pi. The Pi boots using its GPU and SD card, but qemu doesn't have them. Also, Linux kernels for ARM are not interchangeable between machines, so you can't use a Pi kernel on qemu, you can't use a Tegra kernel on the Pi etc etc. But (apart from booting and the kernel) everything else in Slackware ARM is transferable between qemu and the Pi.
If it's any consolation, I actually found qemu more difficult -- and I'm still waiting for my Pi too, but I've borrowed one from a jammy **** who has three!
Wellll, that's not the same thing. Those links show people running non-Pi 'versatile' kernels (which are already available in ARMedslack). Also, the two images I've prepped are partitioned in a way that's obvious for the Pi but nonobvious for qemu (the root partition is partition 2, not partition 1, because on the Pi /boot *must* be vfat, and *must* be p1, and *must* contain the closed source boot blobs). Also also, I've not included the kernel modules for 'versatile' under /lib/modules. I could, but would the extra space be justified? (Actually, thanks to your question, I'm now thinking maybe yes )
So, although those links purport to show people running Pi stuff on qemu, they've done it by ignoring everything that makes the Pi a Pi and using qemu-specific stuff instead.
You could get the same effect with my Pi miniroot I've prepped by adding the versatile modules and then specifying -kernel blah -append "root=/dev/sda2" etc, but if you're going to do that, you're be better off using the official ARMedslack miniroot image -- it's already got all the right stuff for qemu.
As for the installer image, again, if you want to do that in qemu, use the standard ARMedslack installer. My RasPi Installer image is quite different. Slackware's installer images, including ARMedslack, have everything in an separate initrd.gz file. Unfortunately, you can't (currently) use a separate initrd.gz file on the Pi, because the GPU based bootloader doesn't support it. You have to build the initramfs directly into the kernel image itself. That's why you can't use the Pi installer on qemu, and you can't use the qemu installer on the Pi. But really, that's the *only* structural difference between the two installers.
Except for the boot and the kernel, you aren't losing any part of the Pi experience by using standard ARMedslack on qemu -- after all, the whole point is that the Pi experience should be the *same* as standard ARMedslack.
Edit: Umm, I think I may have misunderstood the original question. Yes, you **CAN** run standard ARMedslack on qemu, and there are instructions here INSTALL_QEMU.TXT and tools in the armedslack-devtools. What you can't run directly on qemu is the Pi-specific stuff I've been cranking out. For pragmatic reasons that could change, but the definitive official standard qemu implementation is official standard ARMedslack, the original and still the best Sorry for the confusion!
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.