aboutsummaryrefslogtreecommitdiffstats
path: root/README
blob: 8591fa9f485431ad261935998b6b2558eabe1a68 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
apt-get install genisoimage fuse fuseiso
usermod guilhem -G fuse

make iso-preseed


* Tar:

  IMAGE_TYPE=tar ARCH=i386 make
  image=debian-7.4.0-i386-netinst-preseeded.tar

  device=/dev/disk/by-id/...    # fixme
  mountpoint=/mnt/usbkey        # fixme

  device=$(readlink -f $device)
  parted $device mklabel msdos
  parted $device mkpart primary 1 1G
  parted $device set 1 boot on
  mkdosfs ${device}1

  install-mbr $device
  syslinux -i ${device}1

  mount ${device}1 $mountpoint
  tar -x -C $mountpoint -f $image --no-same-owner
  umount $mountpoint


* ISO:

  make
  image=debian-7.4.0-amd64-netinst-preseeded.iso
  device=/dev/disk/by-id/...
  dd if="$image" of="$device" bs=4M; sync


* To configure a static IP:

  :/etc/default/interface

   auto eth0
   iface eth0 inet static
     pre-up ip addr flush dev $IFACE
     address 171.25.193.76
     gateway 171.25.193.65
     netmask 255.255.255.0

  :/etc/default/grub
    # https://www.kernel.org/doc/Documentation/filesystems/nfs/nfsroot.txt
    # (Edit the kernel parameter in the grub menu if the system doesn't boot.)
    GRUB_CMDLINE_LINUX="ip=171.25.193.76::171.25.193.65:255.255.255.0::eth0:off"
    #GRUB_CMDLINE_LINUX="ip=:::::eth0:dhcp"

  $ sudo update-grub


* To compile an AMD64 image on a i386 machine (or vice versa):

  apt-get install gcc-multilib
  ARCH=amd64 make