~ubuntu-branches/ubuntu/edgy/e2fsprogs/edgy-updates

« back to all changes in this revision

Viewing changes to debian/e2fsprogs.initrd

  • Committer: Bazaar Package Importer
  • Author(s): Tollef Fog Heen
  • Date: 2005-08-23 10:42:10 UTC
  • mfrom: (1.1.2 upstream)
  • Revision ID: james.westby@ubuntu.com-20050823104210-t15igvmgrkzea0dq
Tags: 1.38-2ubuntu1
* Merge with Debian.  (Ubuntu #13757)
* Remove tests/f_bad_disconnected_inode/image.gz to be able to build the
  package.  This will (hopefully) be in the next upstream version and is
  just used for testing.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
#!/bin/sh
2
 
cd /
3
 
mount -nt proc proc proc
4
 
rootdev=$(cat proc/sys/kernel/real-root-dev)
5
 
cmdline=$(cat /proc/cmdline)
6
 
umount -n proc
7
 
if [ $rootdev != 256 ]; then
8
 
    mount -nt tmpfs tmpfs /dev2
9
 
    mount -nt proc proc /proc 
10
 
    mount -nt devfs devfs /devfs > /dev/null 2>&1
11
 
    get_device
12
 
    mount_device
13
 
    if test -f /mnt/etc/fstab ; then
14
 
        ext3root=`awk '!/^ *#/ { if (($2 == "/") && ($3 == "ext3")) {print $1;}}' < /mnt/etc/fstab`
15
 
        ext2root=`awk '!/^ *#/ { if (($2 == "/") && ($3 == "ext2")) {print $1;}}' < /mnt/etc/fstab`
16
 
    fi
17
 
    umount -n /devfs > /dev/null 2>&1
18
 
    umount -n /mnt > /dev/null 2>&1
19
 
    if test -n "$ext3root" -o -n "$ext2root" ; then
20
 
        mount -nt tmpfs tmpfs /etc
21
 
        echo >> /etc/fstab
22
 
        echo >> /etc/mtab
23
 
        if test -n "$ext3root" ; then
24
 
            /sbin/tune2fs -O has_journal /dev2/root2 > /dev/null 2>&1
25
 
        else
26
 
            /sbin/tune2fs -O ^has_journal /dev2/root2 > /dev/null 2>&1
27
 
        fi
28
 
        umount -n /etc
29
 
    fi
30
 
    umount -n /dev2
31
 
    umount -n /proc > /dev/null 2>&1
32
 
fi