


* please note: debootstrap is depreciated way to install to your device and there is easier ways to do what this does, this is for testing and setup to get a functional image to start from and build, and is no way user friendly.
* most of what "i" do with this image is develop, i add a complier, ssh into the device and develop. if you figure out what to do from there good, as far as i guess, hardware differs from device to device too much to be a full and usable system. If you intend to use this setup, great, best of luck, build from it, its a great tool as for the device makes a great machine with plenty of speed to work with.



* im not too eager to post an image to this install
* the instructions need to be followed precisely and you can and will connect on reboot.
* i don' t have a "gates pc", my hardware functions properly, network on the pc needs to be routed correctly, and i don't recommend too much input into the "sde" (nor do i recommend setting up wifi the unit is full root and will be wide open to exploits.)
*if need be boot from a live-cd or pen-drive linux and setup from there, gnome-network manager is very easy to configure, if your hardware is the issue, get a different machine[/quote]
*Again, this is an initial setup and by no means a full install i use this guide to get the device up and running, it will get debian installed and ready for setup for image creation, if you have hardware or network issues look or open another thread
* pm me if you have issues with this setup or the image that i've spent ALOT of time building.
* Again i use this as reference to setup and that is it, any farther than that requires a thread.
* there are many other ways to install debian on the device, and this method is depreciated, again this is for advanced linux operators only * if you have issues in this area and dont understand debian these instructions are not for you seek a different avenue.
[/quote]
questions comments? if i dont answer put it here..
v v v v v v
http://forum.archosfans.com/viewtopic.php?f=34&t=54484
*** thank-you
lew8w8, unknown, Johnnathan, and all the sites, listed in this "instruct"
* all the info here has been a modified instruct
using info from kevin's original here >>> http://dev.openaos.org/wiki/Debian


1. Boot the device into Recovery and select Repair Disk
2. Back up your device
Code: Select all
# from the host pc
mkdir -p ~/archos-backup
cp -axv /media/ARCHOS5/* ~/archos-backup/
(if you have run this script and followed it correctly and have a corrupt install,"dont format the wrong image"
renaming rootfs.img -> debian.img rootfs.original -> rootfs.img and format the debian.img and skip to 7.)
3. Unmount it and format the internal drive
Code: Select all
# from the host pc
sudo fdisk -l
mount
# you will see what device is the a5it and where its mounted
# note the output to find the device
umount /media/ARCHOS5/
sudo mke2fs /dev/sdXX -j -L ARCHOS5
Code: Select all
# from the host pc
# i am assuming that /home/<username>/Downloads/firmware_archos5.aos is the SDE
# your location may be different
sudo cp -axv ~/Downloads/firmware_archos5.aos /media/ARCHOS5/
sync
umount /media/ARCHOS5/
disconnect the usb, power back up into recovery, and select Repair Disk again.
5a. Connect the device and copy the zipped rootfs.img found on the internal drive to your home folder
(we are gonna make room for debian), unzip it so we can format and resize it, format the image, create a 2G empty file in tempand add some empty space to the image then resize to a little over 2G.
Code: Select all
# from the host pc
sudo cp -axv /media/ARCHOS5/rootfs.img.gz ~/.
cd ~
gunzip rootfs.img.gz
sudo mke2fs -j rootfs.img
# dd is a very powerful tool and should be used with caution verify what you are doing before you use it
# it is optional either go with a larger or smaller image try to leave room so you can "play"
dd if=/dev/zero of=/tmp/empty bs=1G count=2
sudo cat /tmp/empty >> rootfs.img
rm /tmp/empty
sudo resize2fs rootfs.img 2G
# 2G is a confortable start, you can also mount more images/resize/endless, thats why i love linux,
# how much depends on your knowledge and needs currently my usr/src directory is 120G (mounted usb)
# and my device is only an a5it-8g-with-andrd
# when these instructions are up i want to see if wifi really works, and if i can get bt and alsa functioning
Code: Select all
# from the host pc
# this next step takes a while...
sudo cp -axv rootfs.img /media/ARCHOS5/debian.img
sync
umount /media/ARCHOS5/
power up and wait for the sde to setup
8. Create a user and a password, select your language, set your time and zones, keys and buttons, and user access, logout then login as usual
9. Select other -> root-shell, set a password for root and enable usb network, edit /etc/networking/interfaces and /etc/resolv.conf, disconnect the usb form the pc and establish a connection to the internet with the pc.
Code: Select all
# again if you cannot gain an address from udhcp using usb g_ether this is NOT going to work for you
# from root-shell on the a5it
passwd
# enable network
rmmod musb_hdrc
modprobe musb_hdrc mode_default=2
modprobe g_ether
# if you get an error No such Device (as i did) unplug and plug in the usb
# edit /etc/network/interfaces
auto lo
iface lo inet loopback
auto usb0
iface usb0 inet dhcp
# comment out anything you dont use
# edit /etc/resolv.conf
nameserver 8.8.8.8
nameserver 8.8.4.4
(*note the ip that udhcp aquires you will need it in the next step)
Code: Select all
# from the root-shell inside the sde
ifdown usb0
ifup usb0
ping google.com
Code: Select all
# from the host machine connected to the internet
ssh [email protected]<*ip that udhcp aquired>
Code: Select all
# from the host machine inside the sde via ssh
mkdir -p /mnt/debian
mount -o loop /mnt_data/debian.img /mnt/debian
mkdir -p /mnt/debian/boot
mkdir -p /mnt/debian/lib/modules
mkdir -p /mnt/debian/lib/firmware
cp -r /boot/* /mnt/debian/boot/
cp -r /lib/modules/* /mnt/debian/lib/modules/
cp -r /lib/firmware/* /mnt/debian/lib/firmware/
mkdir -p /mnt/debian/etc/network
cp -r /etc/network/interfaces /mnt/debian/etc/network/
cp -r /etc/hostname /mnt/debian/etc/
cp -r /etc/fstab /mnt/debian/etc/
cp -r /etc/modules /mnt/debian/etc/
Code: Select all
# from the host machine inside the sde via ssh
wget http://ftp.us.debian.org/debian/pool/main/c/cdebootstrap/cdebootstrap-static_0.5.7_armel.deb
ar -x cdebootstrap-static_0.5.7_armel.deb data.tar.gz
tar -xz -C / -f data.tar.gz
rm data.tar.gz cdebootstrap-static_0.5.7_armel.deb
# next step installs debian with a couple things we need
cdebootstrap-static --flavour=minimal --allow-unauthenticated --include=dhcp3-client,ifupdown,procps,netbase,vim-tiny,module-init-tools,wget,openssh-server,apmd,dialog,man-db,apt-utils squeeze /mnt/debian/ http://ftp.us.debian.org/debian/
# if you have enough room back up the image if you wish now... it is 2G but can be shrunk/compressed
mount -t proc proc /mnt/debian/proc
mount -t devpts devpts /mnt/debian/dev/pts
# thank you Jonathan Moerman
# i think it's ok again
cp -r /etc/resolv.conf /mnt/debian/etc/
## added 7-6 how come i didn't see this mtab never updated in the original
cp /proc/mounts /etc/mtab
chroot /mnt/debian /bin/bash
# from the host machine inside the sde via ssh chrooted into debian
# create move home to /home(optional) and create a password
mv /root /home/root
ln -sf /home/root /root
passwd root
Code: Select all
# from the host machine inside the sde via ssh chrooted into debian
## note: only uncomment during future steps - VERY IMPORTANT - if udev gets installed it will corrupt your install
## debian squeeze on archos 5it
# deb http://ftp.us.debian.org/debian squeeze main contrib non-free
# deb-src http://ftp.us.debian.org/debian squeeze main contrib non-free
deb http://security.debian.org/ squeeze/updates main contrib non-free
deb-src http://security.debian.org/ squeeze/updates main
# deb http://ftp.us.debian.org/debian sid main contrib non-free
# deb-src http://ftp.us.debian.org/debian sid main contrib non-free
###using ubuntu-ports breaks the rc.local script if you enable them you need a different way to interface
## deb http://ports.ubuntu.com/ubuntu-ports natty main universe multiverse restricted
## deb-src http://ports.ubuntu.com/ubuntu-ports natty main universe multiverse restricted
## note: only uncomment during future steps - VERY IMPORTANT - if udev gets installed it will corrupt your install
Code: Select all
# from the host machine inside the sde via ssh chrooted into debian
cat > /usr/sbin/ping_atmega <<__END__
#!/bin/sh
##/usr/sbin/ping_atmega
while true; do
head -c 4 /dev/atmg > /dev/null
sleep 60
done
__END__
chmod +x /usr/sbin/ping_atmega
Code: Select all
# from the host machine inside the sde via ssh
#!/bin/sh -e
# rc.local
modprobe musb_hdrc
/usr/sbin/ping_atmega &
rmmod musb_hdrc
modprobe musb_hdrc mode_default=2
modprobe g_ether
/sbin/ifdown usb0 &
sleep 3
/sbin/dhclient usb0 &
/sbin/ifup usb0 dhcp &
exit 0
for this step we need to uncomment sid to install locales
Code: Select all
# from the host machine inside the sde via ssh chrooted into debian
echo nameserver 8.8.8.8 nameserver 8.8.4.4 > /etc/resolv.conf
### changes made 7-6
# for this step we need to uncomment sid to install locales from /etc/apt/sources.list as explained earlier
# libc-bin libc6 are going to be updated
apt-get update
apt-get install locales
# edit /etc/locale.gen and uncomment your needed locales
locale-gen
[code]
apt-get install nodm libfs6 libglu1-mesa libpng12-0 libts-0.0-0 libts-bin tsconf x11-apps x11-session-utils x11-xfs-utils xfonts-100dpi xfonts-75dpi xfonts-scalable xorg xorg-docs-core xserver-xorg-input-tslib
# i selected USA (just a guess the device keyboard is invisable)
# script edits /etc/default/nodm and change autostart from false to true
# root should auto start nodm and enlightement
# edit /etc/default/nodm and change autostart from false to true root will auto start nodm, and enlightement
# you can't enable a user at this time you need root privelages to get things working inside then create a user after the install
apt-get update
apt-get install e17
# 87 new installs and liblocale-gettext-perl libtext-charwidth-perl libtext-iconv-perl perl-base get upgraded
# unless you have another interface idea
# time to lie to x and create calibration files
cat > /etc/pointercal<<__END__
793 0 -95501 0 508 -116804 3830
__END__
mkdir -p /etc/X11/xorg.conf.d
cat > /etc/X11/xorg.conf.d/99-touchcal.conf<<__END__
Section "InputClass"
Identifier "calibration"
MatchProduct "ADS2008 Touchscreen"
Option "Calibration" "117 3929 217 3854"
EndSection
__END__
# edit /etc/apt/sources.list and comment out sid and uncomment squeeze
# this should get nodm to start on next reboot
pkill gpe
apt-get update
apt-get remove nodm
apt-get install nodm
# Kevin's scripts were removed, if you want them see here -> http://dev.openaos/wiki/Debian
# (make sure squeeze is the only repo enabled)
apt-get --yes --purge remove cdebootstrap-helper-rc.d
apt-get update
# exit the "jail" unmount everything and reboot
exit
umount /mnt/debian/dev/pts
umount /mnt/debian/sys
umount /mnt/debian/proc
sync
umount /mnt/debian
sync
reboot & exit
[/code]
18. Make sure the device restarts, login and logout/shutdown using the menu, then reboot into recovery select repair drive and mount it to your pc.
...ok take a deep breath we're almost there


Code: Select all
# from the host pc and the a5it boooted to recovery/repairdisk
sudo mv /media/ARCHOS5/rootfs.img /media/ARCHOS5/rootfs.original
sudo mv /media/ARCHOS5/debian.img /media/ARCHOS5/rootfs.img
sync
umount /media/ARCHOS5/
the pc should already be connected,
###if nodm fails to start establish a connection and install nodm from squeeze
we're done with the install
every thing from here down is just notations
connection. From the pc, ping the subnet that the usb is on to find the device, then ssh into it using the password you created during installation (*if your internet is 192.168.1.X then the subnet is probably 10.42.43.X. The first 3 sets will be the same as the ip you used earlier to log into the sde)
***example: ssh [email protected]?
*** if your touch works open xterm from the menu and ipconfig
# test your touch at this time to see if it works at this step if not continue
(the device should auto-connect and keep its dhcp lease)
on the pc do the following to calibrate the screen(if needed)
# from the host pc sshed into debian install

TSLIB_TSDEVICE=/dev/input/event2 ts_calibrate
yes this works! updates /etc/pointercal correctly
as promised: the image that it created
have fun http://www.megaupload.com/?d=K97PGF1K
* edit rc.local and remove .sh from ping_atmega.sh & (see step 15)

****also further note, if for some reason the device does not start x or the filesysem gets "fragged"
restart into recovery rename the rootf back to debian.image and rootfs.original back to rootfs.img and it will boot as the normal sde did before the install, and you can chroot into it and make repairs or edits there
****or set up you device the old way you had it....
****problems? pm me and let some other successors have the floor...
****there may be someone else with an idea for "debian on an it?"