You are not logged in.

#1 2010-11-05 00:51:42

valvet
Member
From: Denmark
Registered: 2009-06-06
Posts: 147

[SOLVED] Trying to install Arch Linux from harddisk using /dev/sda2

Hi

I'm trying to install Arch using my swap partition, following this wiki entry: https://wiki.archlinux.org/index.php/Ha … stallation

What I've done:

Downloaded ISO: archlinux-2010.05-netinstall-i686.iso
Command: swapoff /dev/sda2
Command: fdisk /dev/sda and changed the system type to 83 (Linux) on /dev/sda2

Now it looks like:

Command (m for help): p

Disk /dev/sda: 250.1 GB, 250059350016 bytes
255 heads, 63 sectors/track, 30401 cylinders, total 488397168 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00017e5b

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1     1060289      530144+  83  Linux
/dev/sda2         1060290     3164804     1052257+  83  Linux
/dev/sda3         3164805   105579179    51207187+  83  Linux
/dev/sda4       105579180   488392064   191406442+  83  Linux

It complained about device was busy, but it still seemed to have changed the system type, so I did partprobe as it wrote.

WARNING: Re-reading the partition table failed with error 16: Device or resource busy.
The kernel still uses the old table. The new table will be used at
the next reboot or after you run partprobe(8) or kpartx(8)
Syncing disks.
[root@swamp ~]# partprobe 
<no output>

Next I did:

[root@swamp ~]# dd if=archlinux-2010.05-netinstall-i686.iso of=/dev/sda2
327680+0 records in
327680+0 records out
167772160 bytes (168 MB) copied, 4.3025 s, 39.0 MB/s
[root@swamp ~]# mkdir /mnt/sda2
[root@swamp ~]# mount /dev/sda2 /mnt/sda2
mount: warning: /mnt/sda2 seems to be mounted read-only.
[root@swamp ~]# ls -al /mnt/sda2
total 150466
dr-xr-xr-x 3 root root       240 May 16 15:54 .
drwxr-xr-x 6 root root      4096 Nov  5 01:40 ..
dr-xr-xr-x 3 root root       556 May 16 15:52 boot
-r--r--r-- 1 root root       448 May 16 15:54 isomounts
-r--r--r-- 1 root root      8192 May 16 15:54 overlay.sqfs
-r--r--r-- 1 root root 154058752 May 16 15:54 root-image.sqfs

And unmounted it again.

The wiki page says to type: fsck -f /dev/sda2fsck, but I get no such file while trying to open sda2fsck.

[root@swamp ~]# fsck -f /dev/sda2fsck
fsck from util-linux-ng 2.18
e2fsck 1.41.12 (17-May-2010)
fsck.ext2: No such file or directory while trying to open /dev/sda2fsck

The superblock could not be read or does not describe a correct ext2
filesystem.  If the device is valid and it really contains an ext2
filesystem (and not swap or ufs or something else), then the superblock
is corrupt, and you might try running e2fsck with an alternate superblock:
    e2fsck -b 8193 <device>

Can I ignore the above and continue modifying grub?

Thanks :-)

Last edited by valvet (2010-11-08 14:49:07)

Offline

#2 2010-11-05 01:09:43

valvet
Member
From: Denmark
Registered: 2009-06-06
Posts: 147

Re: [SOLVED] Trying to install Arch Linux from harddisk using /dev/sda2

Ok, I diden't actually need to install grub again.. I tried rebooting and doing:

root (0,1) <- /dev/sda2 I hope

But grub tells me: Unknown filesystem type (83).

Do I need to partition this newly unswapped /dev/sda somehow?

Offline

#3 2010-11-05 05:16:17

dardyfella
Member
Registered: 2010-11-05
Posts: 3

Re: [SOLVED] Trying to install Arch Linux from harddisk using /dev/sda2

I have no experience in doing this, but the line for dd seems to be missing the skip parameter thats used in the wiki page you linked which might be why you can't boot because grub keeps overwriting the first 63 sectors of your /dev/sda2. If you don't skip the sectors then the beginning of the swap partition will get overwritten by grub making it unrecognizable by any mounting procedure.

Also, the install image has to have the correct modules/bootstrap loader. It seems you've got the one for a CD/DVD-ROM because you have isomounts whilst one for a hard drive or a usb drive might have syslinux or some such. Correct me if I'm wrong however.

Like I said, I have no experience with this installation method but it just seems like you are missing some details here and there.

Offline

#4 2010-11-05 06:44:53

sand_man
Member
From: Australia
Registered: 2008-06-10
Posts: 2,164

Re: [SOLVED] Trying to install Arch Linux from harddisk using /dev/sda2

fsck -f /dev/sda2fsck makes no sense because /dev/sda2fsck is not a deivce. If the wiki says that, then it is wrong. It's only doing a fsck anyway so probably not really needed. If you are just formatting th swap partition then use, mkfs.ext{234}.

edit:
from the wiki

 # fsck -f /dev/sda2fsck 1.40.8 (13-Mar-2008)
 e2fsck 1.40.8 (13-Mar-2008)
 Pass 1: Checking inodes, blocks, and sizes
 Pass 2: Checking directory structure
 Pass 3: Checking directory connectivity
 Pass 3A: Optimizing directories
 Pass 4: Checking reference counts
 Pass 5: Checking group summary information
 
 /dev/sda2: ***** FILE SYSTEM WAS MODIFIED *****
 /dev/sda2: 243/78936 files (8.2% non-contiguous), 310519/314880 blocks

The first like should just be

# fsck -f /dev/sda2

Last edited by sand_man (2010-11-05 06:46:01)


neutral

Offline

Board footer

Powered by FluxBB