Installing Debian

Fera
Posts: 11
Joined: Mon Nov 28, 2011 12:55 pm

Installing Debian

Post by Fera » Wed Nov 30, 2011 8:31 pm

and can u help me plz and guide me how to put debian on it?

Mijzelf
Posts: 6226
Joined: Mon Jun 16, 2008 10:45 am

Re: 2Big Drive Image help

Post by Mijzelf » Thu Dec 01, 2011 6:55 pm

OK, I'll try.

The bootloader in flash (u-boot) loads the kernel from sda6 (uImage), and starts it. The kernel gets a commandline passed which tells to mount sda7 as rootfs, read only.
So to boot Debian you basically have to provide a suitable kernel in sda6, and a Debian rootfs in sda7.

Connect one of the disks to a Linux PC, find the right devicename by executing

Code: Select all

cat /proc/partitions
I'll assume it's sdb.
Use fdisk to create an extended partition of, lets say, 6GB.

Code: Select all

fdisk /dev/sdb
(If the disk isn't empty, first delete all partitions)
Then create logical partitions,
1st (sdb5) 512MB, type swap.
2nd (sdb6) 8MB type raw (if such a type exists. It doesn't really matter).
3nd (sdb7) 4GB type linux.

Prepare the partitions:

Code: Select all

mkswap /dev/sdb5
mke2fs -j /dev/sdb7
Now you need a kernel and a rootfs. A kernel can be foundhere, 2big_uImage_modules.tar.gz.
Further you need a Debian rootfs. That can be found here, lenny.tgz.
Mount sdb7, and extract the rootfs:

Code: Select all

mkdir /tmp/sdb7
mount /dev/sdb7 /tmp/sdb7
cd /tmp/sdb7
tar xzf /path/to/lenny.tgz
# add the kernel and modules
tar xzf /path/to/2big_uImage_modules.tar.gz
# write the kernel to sdb6
dd if=uImage of=/dev/sdb6
Now edit /tmp/sdb7/etc/fstab. The rootfs will be mounted read-only, but Debian doesn't like that. So add a line to remount it rw:

Code: Select all

/dev/sda7   /   ext3   defaults,ro   0 0
Basically this is it. If you put this disk in your 2Big, it should boot to Debian.
  • The box will request an IP address by DHCP.
  • A lightweight ssh server will be running (dropbear)
  • There are two users, user with password user, and root with password root.
I have no idea what the fan will do.

Fera
Posts: 11
Joined: Mon Nov 28, 2011 12:55 pm

Re: 2Big Drive Image help

Post by Fera » Fri Dec 02, 2011 8:00 pm

Sorry but i don't understand nothing of that... can u explain me step by step how to do that, think my HD is empty (no partitions) and i don't know nothing about the lacie 2big network, that way i can make this work ;)

i hope you can help me

Mijzelf
Posts: 6226
Joined: Mon Jun 16, 2008 10:45 am

Re: 2Big Drive Image help

Post by Mijzelf » Sat Dec 03, 2011 12:41 pm

Fera wrote:can u explain me step by step how to do that
Sorry, I don't think that would lead to something meaningful. My directions are pretty step by step, I think. When you need a lot more help to get Debian running, you wouldn't be able to do anything with Debian anyway, as it out of the box only gives you a command shell.

Fera
Posts: 11
Joined: Mon Nov 28, 2011 12:55 pm

Re: 2Big Drive Image help

Post by Fera » Mon Dec 05, 2011 12:04 pm

I'm so sorry... i was with my head in another place... i will try today to see if i can make debian run on it ;) thanks a lot for the help ;)

Fera
Posts: 11
Joined: Mon Nov 28, 2011 12:55 pm

Re: 2Big Drive Image help

Post by Fera » Wed Dec 07, 2011 8:45 pm

Hey men, i have a question, i have done al the steps you told me on the previous post, now the 2big with the disc doesn't turn off automatically, but there's nothing new on my net, it's seems to be running but i can't find its IP Address do u have any idea how can i config the drive?

Another question, what happend if i install debian on the disk normally? (the disk connected on a PC and install ir by the normal way) it will work on the 2big?

I hope you can answer me ;)

Mijzelf
Posts: 6226
Joined: Mon Jun 16, 2008 10:45 am

Re: 2Big Drive Image help

Post by Mijzelf » Thu Dec 08, 2011 10:13 am

Fera wrote:there's nothing new on my net
How did you check that? The NAS doesn't run any Netbios client, so it's won't popup in 'Network neighborhood' or sonething like that. Nor will the Lacie discovery tool detect it (it's not running Lacie firmware anymore).
The only way to find that box is to look in the logfiles of your DHCP server (router), or to do a network scan. (With something like this.

If it's really not in the network, connect the drive to your PC again, and look if you can find anything in sda7/var/log/. dmesg and messages could be very helpful in finding the problem.
Fera wrote:Another question, what happend if i install debian on the disk normally?
'Normally' as in installing on a PC from a CD? That won't work. It will install a X86 or X64 bootable disk, but the NAS has an ARM processor.

Fera
Posts: 11
Joined: Mon Nov 28, 2011 12:55 pm

Re: 2Big Drive Image help

Post by Fera » Fri Dec 09, 2011 9:16 pm

Ok, i understand why i cannot install debian directly on the disk, and i search for some logs on /dev/sdb7/var/log/term.log

and it says this:

Can not write log, openpty() failed (/dev/pts not mounted?)
Can not write log, openpty() failed (/dev/pts not mounted?)





I hope you can help me with this

Mijzelf
Posts: 6226
Joined: Mon Jun 16, 2008 10:45 am

Re: Installing Debian

Post by Mijzelf » Sat Dec 10, 2011 10:22 am

I just extracte the lenny.tgz, and the file /var/log/apt/term.log is already there:

Code: Select all

Log started: 2010-11-21  14:01:34
Can not write log, openpty() failed (/dev/pts not mounted?)
Can not write log, openpty() failed (/dev/pts not mounted?)
Log ended: 2010-11-21  14:07:14[/quote]I suppose it's an artifact of the chroot I used to build the packet. 
Further there are to files in /var/log/fsck, checkfs and checkroot, both from nov 21 2010. So unless your file is different, or you've got more files, there is nothing written at all.
So either the system didn't boot at all, or the rootfs cannot be written.

How is you /etc/fstab now?

Fera
Posts: 11
Joined: Mon Nov 28, 2011 12:55 pm

Re: Installing Debian

Post by Fera » Mon Dec 12, 2011 8:29 pm

The fstab shows this

Code: Select all

# UNCONFIGURED FSTAB FOR BASE SYSTEM
/dev/sda5 swap swap defaults 0 0
/dev/sda2 /home auto defaults 0 0
/dev/sda7 /ext3 defualts,ro 0 0
that's what the fstab shows...

Mijzelf
Posts: 6226
Joined: Mon Jun 16, 2008 10:45 am

Re: Installing Debian

Post by Mijzelf » Mon Dec 12, 2011 8:35 pm

Typo of yours, and error of me. The last line should be

Code: Select all

/dev/sda7 / ext3 defaults,rw 0 0
Don't forget the space between / and ext3

Fera
Posts: 11
Joined: Mon Nov 28, 2011 12:55 pm

Re: Installing Debian

Post by Fera » Tue Dec 13, 2011 12:17 pm

well, i put the space between / and ext3, and changed the "defaults,ro" for "defaults,rw", but still nothing happend, i have search for the log files and nothing special, and scan my network for something new, and still nothing... :(

if you use skype we can try to solve that way and maybe remote connection.

Thanks for all and i hope you're not too bored of me.

Mijzelf
Posts: 6226
Joined: Mon Jun 16, 2008 10:45 am

Re: Installing Debian

Post by Mijzelf » Tue Dec 13, 2011 7:05 pm

Fera wrote:/dev/sda7 /ext3 defualts,ro 0 0
Fera wrote:and changed the "defaults,ro" for "defaults,rw"
Did you change defualts to defaults?

Fera
Posts: 11
Joined: Mon Nov 28, 2011 12:55 pm

Re: Installing Debian

Post by Fera » Wed Dec 14, 2011 11:51 am

it's this way now

Code: Select all

# UNCONFIGURED FSTAB FOR BASE SYSTEM
/dev/sda5 swap swap defaults 0 0
/dev/sda2 /home auto defaults 0 0
/dev/sda7 / ext3 defualts,rw 0 0

Mijzelf
Posts: 6226
Joined: Mon Jun 16, 2008 10:45 am

Re: Installing Debian

Post by Mijzelf » Wed Dec 14, 2011 3:43 pm

Right. Ehh, wrong. the 'defualts' in the last line should still be 'defaults'.
(Even the spelling checker of my browser is complaining)

Post Reply