Как переместить существующую установку Solaris11 на новый диск

Внимание! Это временно отключает диалоговое окно подтверждения.

macro index,pager a ":set confirmappend=no<enter><tag-prefix><copy-message>=Archive<enter><sync-mailbox>:set confirmappend=yes<enter>" Archive
1
09.01.2021, 02:37
1 ответ

Мне удалось найти решение моей проблемы:

  • загрузка с dvd/iso
  • запустить консоль

создать метку диска и структуру разделов

root@solaris:~# format c2t1d0

selecting c2t1d0 <VMware,-VMware Virtual S-1.0-16.00GB>
[disk formatted]

FORMAT MENU:
        disk       - select a disk
        type       - select (define) a disk type
        partition  - select (define) a partition table
        current    - describe the current disk
        format     - format and analyze the disk
        fdisk      - run the fdisk program
        repair     - repair a defective sector
        label      - write label to the disk
        analyze    - surface analysis
        defect     - defect list management
        backup     - search for backup labels
        verify     - read and display labels
        inquiry    - show disk ID
        volname    - set 8-character volume name
        !<cmd>     - execute <cmd>, then return
        quit
format> part

PARTITION MENU:
        0      - change `0' partition
        1      - change `1' partition
        2      - change `2' partition
        3      - change `3' partition
        4      - change `4' partition
        5      - change `5' partition
        6      - change `6' partition
        select - select a predefined table
        modify - modify a predefined partition table
        name   - name the current table
        print  - display the current table
        label  - write partition map and label to the disk
        !<cmd> - execute <cmd>, then return
        quit
partition> print
Current partition table (original):
Total disk sectors available: 33537981 + 16384 (reserved sectors)

Part      Tag    Flag     First Sector        Size        Last Sector
  0  BIOS_boot    wm                40     260.00MB         532519
  1        usr    wm            532520      15.74GB         33538013
  2 unassigned    wm                 0          0              0
  3 unassigned    wm                 0          0              0
  4 unassigned    wm                 0          0              0
  5 unassigned    wm                 0          0              0
  6 unassigned    wm                 0          0              0
  8   reserved    wm          33538015       8.00MB         33554398

partition> quit


FORMAT MENU:
        disk       - select a disk
        type       - select (define) a disk type
        partition  - select (define) a partition table
        current    - describe the current disk
        format     - format and analyze the disk
        fdisk      - run the fdisk program
        repair     - repair a defective sector
        label      - write label to the disk
        analyze    - surface analysis
        defect     - defect list management
        backup     - search for backup labels
        verify     - read and display labels
        inquiry    - show disk ID
        volname    - set 8-character volume name
        !<cmd>     - execute <cmd>, then return
        quit
format> quit

создать новый zpool на слайсе 1 нового диска

root@solaris:~# zpool create rpool1 c2t1d0s1

создать рекурсивный снимок исходного zpool

root@solaris:~# zfs snapshot -r rpool@now

 скопировать снимок через zfs send|receive в новый zpool

root@solaris:~# zfs send -R rpool@now | zfs recv -Fdu rpool1

экспортировать оба zpool 

root@solaris:~# zpool export rpool
root@solaris:~# zpool export rpool1

импортировать новый пул под именем исходного пула

root@solaris:~# zpool import -f rpool1 rpool

активировать загрузочную среду 

root@solaris:~# beadm activate be://rpool/solaris

установить загрузчик на новый диск

root@solaris:~# bootadm install-bootloader -P rpool

активировать загрузочную среду (без второй активации произошла ошибка)

root@solaris:~# beadm activate be://rpool/solaris

список снимков 

root@solaris:~# zfs list -t snapshots

удалить снимки

root@solaris:~ # zfs destroy -R rpool@now

перезагрузка

root@solaris:# reboot

удалить старый диск из системы

3
18.03.2021, 22:37

Теги

Похожие вопросы