Updates für 4.2 stable und testing

Neuigkeiten und Ankündigungen
Patrick89bvb
Beiträge: 44
Registriert: 05 Nov 2015, 11:26

Re: Updates für 4.2 stable und testing

Beitrag von Patrick89bvb »

Hallo Herr Radtke,

ich kam endlich zu meinem Test, leider habe ich das erwünsche Ergebnis nicht hinbekommen.

Um auch etwas vornweg zu kommen, ich habe bisher null Erfahrung mit Autoinstall und habe mich mit der Anleitung etwas beholfen:
https://curtin.readthedocs.io/en/latest ... orage.html

Ich habe zunächst eine Ubuntu Server Installation mitsamt LVM crypt durchgeführt, hier der Inhalt der Datei "autoinstall-user-data":

Code: Alles auswählen

#cloud-config
autoinstall:
  apt:
    disable_components: []
    geoip: true
    preserve_sources_list: false
    primary:
    - arches:
      - amd64
      - i386
      uri: http://archive.ubuntu.com/ubuntu
    - arches:
      - default
      uri: http://ports.ubuntu.com/ubuntu-ports
  drivers:
    install: false
  identity:
    hostname: test
    password: $6$3JRV75CipE9/ENbD$PW641.5AQtk0YpbaUZbuHTw7TMe0j1ofI1uW6XLb65f6D1qxoo2cpY.jPbJrpwT61qkNC/PlM0JcbozOznIWK1
    realname: test
    username: test
  kernel:
    package: linux-generic
  keyboard:
    layout: de
    toggle: null
    variant: nodeadkeys
  locale: de_DE.UTF-8
  network:
    ethernets:
      enp2s0f0:
        dhcp4: true
      enp6s0:
        dhcp4: true
    version: 2
    wifis: {}
  ssh:
    allow-pw: true
    authorized-keys: []
    install-server: false
  storage:
    config:
    - ptable: gpt
      serial: SAMSUNG_MZVLB512HBJQ-xxxx
      wwn: eui.xxxx
      path: /dev/nvme0n1
      wipe: superblock
      preserve: false
      name: ''
      grub_device: false
      type: disk
      id: disk-nvme0n1
    - device: disk-nvme0n1
      size: 1127219200
      wipe: superblock
      flag: boot
      number: 1
      preserve: false
      grub_device: true
      type: partition
      id: partition-0
    - fstype: fat32
      volume: partition-0
      preserve: false
      type: format
      id: format-0
    - device: disk-nvme0n1
      size: 2147483648
      wipe: superblock
      flag: ''
      number: 2
      preserve: false
      grub_device: false
      type: partition
      id: partition-1
    - fstype: ext4
      volume: partition-1
      preserve: false
      type: format
      id: format-1
    - device: disk-nvme0n1
      size: 508833038336
      wipe: superblock
      flag: ''
      number: 3
      preserve: false
      grub_device: false
      type: partition
      id: partition-2
    - volume: partition-2
      keyfile: /tmp/luks-key-i3ft3dd2
      preserve: false
      type: dm_crypt
      id: dm_crypt-0
    - name: ubuntu-vg
      devices:
      - dm_crypt-0
      preserve: false
      type: lvm_volgroup
      id: lvm_volgroup-0
    - name: ubuntu-lv
      volgroup: lvm_volgroup-0
      size: 107374182400B
      wipe: superblock
      preserve: false
      type: lvm_partition
      id: lvm_partition-0
    - fstype: ext4
      volume: lvm_partition-0
      preserve: false
      type: format
      id: format-2
    - path: /
      device: format-2
      type: mount
      id: mount-2
    - path: /boot
      device: format-1
      type: mount
      id: mount-1
    - path: /boot/efi
      device: format-0
      type: mount
      id: mount-0
  updates: security
  version: 1
Jetzt eure ubuntu22-04.yml in /custom/ kopiert und modifiziert:

Code: Alles auswählen

#cloud-config
autoinstall:
  apt:
    disable_components: []
    geoip: true
    preserve_sources_list: false
    primary:
    - arches:
      - amd64
      - i386
      uri: #@online_repository*#
  user-data:
    timezone: #@timezone*#
    disable_root: false
    chpasswd:
      list: |
        root:#@rootpassenc*#
  identity:
    hostname: #@hostname*#
    password: #@userpassenc*#
    realname: #@username*#
    username: #@username*#
  kernel:
    package: linux-generic
  keyboard:
    layout: #@language*#
    toggle: null
    variant: ''
  locale: #@locale*#.UTF-8
  storage:
    layout:
      name: #@partition_method*# 
      match:
        serial: #@disk_serial*#
    config:
    - ptable: gpt
      path: #@partition_disk*#
      wipe: superblock
      preserve: false
      name: ''
      grub_device: false
      type: disk
      id: disk-nvme0n1
    - device: disk-nvme0n1
      size: 1127219200
      wipe: superblock
      flag: boot
      number: 1
      preserve: false
      grub_device: true
      type: partition
      id: partition-0
    - fstype: fat32
      volume: partition-0
      preserve: false
      type: format
      id: format-0
    - device: disk-nvme0n1
      size: 2147483648
      wipe: superblock
      flag: ''
      number: 2
      preserve: false
      grub_device: false
      type: partition
      id: partition-1
    - fstype: ext4
      volume: partition-1
      preserve: false
      type: format
      id: format-1
    - device: disk-nvme0n1
      size: 508833038336
      wipe: superblock
      flag: ''
      number: 3
      preserve: false
      grub_device: false
      type: partition
      id: partition-2
    - volume: partition-2
      key: lukstest
      preserve: false
      type: dm_crypt
      id: dm_crypt-0
    - name: ubuntu-vg
      devices:
      - dm_crypt-0
      preserve: false
      type: lvm_volgroup
      id: lvm_volgroup-0
    - name: ubuntu-lv
      volgroup: lvm_volgroup-0
      size: 107374182400B
      wipe: superblock
      preserve: false
      type: lvm_partition
      id: lvm_partition-0
    - fstype: ext4
      volume: lvm_partition-0
      preserve: false
      type: format
      id: format-2
    - path: /
      device: format-2
      type: mount
      id: mount-2
    - path: /boot
      device: format-1
      type: mount
      id: mount-1
    - path: /boot/efi
      device: format-0
      type: mount
      id: mount-0
  network:
    ethernets:
      #@network_device*#:
        critical: true
        dhcp-identifier: mac
        dhcp4: true
        nameservers:
          addresses:
          - #@nameserveraddress*#
          search:
          - #@dnsdomain*#
    version: 2
  proxy: #@proxy_addr*#
  packages:
  - #@desktop_package*#
  - lsb-release
  - vim
  - lsof
  - cifs-utils
  - dnsutils
  - librsync-dev
  - pkg-config
  ssh:
    allow-pw: true
    authorized-keys: []
    install-server: true
  version: 1
Ich sehe, dass die Partitionierung geklappt hat und der LVM-Volumen erzeugt wurde. Aber mein Test "key: lukstest" wurde nicht abgefragt. :?:
Benutzeravatar
m.radtke
uib-Team
Beiträge: 1517
Registriert: 10 Jun 2015, 12:19

Re: Updates für 4.2 stable und testing

Beitrag von m.radtke »

Hi

die Version in opsi 4.2 experimental (4.2.0.1-10) hat nun das entsprechende Property drin. Es erstellt aber nur eine LVM Partition angelegt.

Gruß
Mathias
Kein Support per DM!
_________________________
opsi support - http://www.uib.de/
For productive opsi installations we recommend support contracts.
Antworten