# format

AVAILABLE DISK SELECTIONS:
0. c1t0d0 <LSI-MR9261-8i-2.12-557.86GB>
/pci@0,0/pci8086,3c0a@3,2/pci1000,9263@0/sd@0,0
1. c1t1d0 <LSI-MR9261-8i-2.12-2.72TB>
/pci@0,0/pci8086,3c0a@3,2/pci1000,9263@0/sd@1,0

Specify disk (enter its number): 1    ————     这里默认系统已发现硬盘

format> fdisk

No fdisk table exists. The default partition for the disk is:

a 100% "SOLARIS System" partition

Type "y" to accept the default partition,  otherwise type "n" to edit the partition table.

WARNING: Disk is larger than 2TB. Solaris partition will be limited to 2 TB.

n  —————— 输入n表示不使用默认的分区方案

SELECT ONE OF THE FOLLOWING:
1. Create a partition
2. Specify the active partition
3. Delete a partition
4. Change between Solaris and Solaris2 Partition IDs
5. Edit/View extended partitions
6. Exit (update disk configuration and exit)
7. Cancel (exit without updating disk configuration)
Enter Selection: 1  ————  输入1表示创建分区
Select the partition type to create:
1=SOLARIS2 2=UNIX 3=PCIXOS 4=Other 5=DOS12
6=DOS16 7=DOSEXT 8=DOSBIG 9=DOS16LBA A=x86 Boot
B=Diagnostic C=FAT32 D=FAT32LBA E=DOSEXTLBA F=EFI (Protective)
G=EFI_SYS 0=Exit? 
F    ——————————输入F表示创建EFI类型的分区
SELECT ONE OF THE FOLLOWING:
1. Create a partition
2. Specify the active partition
3. Delete a partition
4. Change between Solaris and Solaris2 Partition IDs
5. Edit/View extended partitions
6. Exit (update disk configuration and exit)
7. Cancel (exit without updating disk configuration)
Enter Selection: 6    ——————输入6表示保存并退出

在root用户下输入format命令:

root@lnltedmr-tds:~# format
Searching for disks...done

AVAILABLE DISK SELECTIONS:
0. c1t0d0 <LSI-MR9261-8i-2.12-557.86GB>
/pci@0,0/pci8086,3c0a@3,2/pci1000,9263@0/sd@0,0
1. c1t1d0 <LSI-MR9261-8i-2.12-2.72TB>
/pci@0,0/pci8086,3c0a@3,2/pci1000,9263@0/sd@1,0
Specify disk (enter its number): 0  ————选择0号磁盘
selecting c1t0d0 <LSI-MR9261-8i-2.12-557.86GB>
[disk formatted]
/dev/dsk/c1t0d0s1 is part of active ZFS pool rpool. Please see zpool(8).  ——————format程序告诉你这块逻辑盘属于ZFS文件系统

FORMAT MENU:  ————————列出format>下的子命令
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> fdisk  ————————执行fdisk创建分区(partition是选择分区)

Total disk size is 36412 cylinders
Cylinder size is 32130 (512 byte) blocks

Cylinders
Partition Status Type Start End Length %
========= ====== ============ ===== === ====== ===
1 EFI 0 36412 36413 100

SELECT ONE OF THE FOLLOWING:
1. Create a partition
2. Specify the active partition
3. Delete a partition
4. Change between Solaris and Solaris2 Partition IDs
5. Edit/View extended partitions
6. Exit (update disk configuration and exit)
7. Cancel (exit without updating disk configuration)
Enter Selection: 7

format> partition    ——————选择分区

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: 5849583549 + 16384 (reserved sectors)

Part Tag Flag First Sector Size Last Sector
0 usr wm 34 2.72TB 5849583582 
1 unassigned wm 0 0 0 
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 5849583583 8.00MB 5849599966

partition>

# format
Specify disk (enter its number): 1
format> fdisk    
Type "y" to accept the default partition, otherwise type "n" to edit the partition table. n
SELECT ONE OF THE FOLLOWING:
1. Create a partition
2. Specify the active partition
3. Delete a partition
4. Change between Solaris and Solaris2 Partition IDs
5. Edit/View extended partitions
6. Exit (update disk configuration and exit)
7. Cancel (exit without updating disk configuration)
Enter Selection: 1    ————创建分区
Select the partition type to create:
1=SOLARIS2 2=UNIX 3=PCIXOS 4=Other 5=DOS12
6=DOS16 7=DOSEXT 8=DOSBIG 9=DOS16LBA A=x86 Boot
B=Diagnostic C=FAT32 D=FAT32LBA E=DOSEXTLBA F=EFI (Protective)
G=EFI_SYS 0=Exit? 
F    —————— EFI类型
SELECT ONE OF THE FOLLOWING:
1. Create a partition
2. Specify the active partition
3. Delete a partition
4. Change between Solaris and Solaris2 Partition IDs
5. Edit/View extended partitions
6. Exit (update disk configuration and exit)
7. Cancel (exit without updating disk configuration)
Enter Selection: 6    ————保持分区配置并退出

查找硬盘devfsadm(sol9 up),drvconfig,disks;(sol8 down)

format
0
1
......
(choose disk)1
save
p
partition>m(非挂接区)
修改吧。
partition>label
partition>quit
format>quit

newfs /dev/dsk/cXtXdXsX
保险起见把输出的这些数字保存到文件中,以备以后查看。

凭记忆写的,应该可以吧。

partition> m
Cannot modify disk partitions while it has mounted partitions.

必须一块盘上的所有分区都 umount 么?

right

不然拿光盘引导系统,然后更改分区吧。

创建基本 ZFS 文件系统

ZFS 管理在设计过程中考虑了简单性。其设计目标之一是减少创建可用文件系统所需的命令数。例如,创建新池的同时会创建一个新 ZFS 文件系统,并自动将其挂载。

https://docs.oracle.com/cd/E37934_01/html/E36658/gaypm.html#scrolltoc

管理 ZFS 挂载点

缺省情况下,ZFS 文件系统在创建时自动挂载。可以确定文件系统的特定挂载点行为,如本节所述。

另外,也可以在创建时使用 zpool create 的 -m 选项为池文件系统设置缺省挂载点。有关创建池的更多信息,请参见创建 ZFS 存储池

所有 ZFS 文件系统都由 ZFS 通过使用服务管理工具 (Service Management Facility, SMF) 的 svc://system/filesystem/local 服务在引导时挂载。文件系统挂载在 /path 下,其中 path 是文件系统的名称。

可以使用 zfs set 命令将 mountpoint 属性设置为特定路径,以覆盖缺省挂载点。ZFS 自动创建指定的挂载点(如果需要),并自动挂载关联的文件系统。

ZFS 文件系统无需您编辑 /etc/vfstab 文件即可在引导时自动挂载。

mountpoint 属性是继承的。例如,如果 pool/home 的 mountpoint 属性设置为 /export/stuff,则 pool/home/user 将继承 /export/stuff/user 的 mountpoint 属性值。

要阻止文件系统被挂载,须将 mountpoint 属性设置为 none。此外,canmount 属性可以用来控制是否能挂载文件系统。有关 canmount 属性的更多信息,请参见canmount 属性

也可以使用 zfs set 将 mountpoint 属性设置为 legacy,从而通过传统挂载接口显式管理文件系统。这样做可以防止 ZFS 自动挂载和管理文件系统。不过必须改用包括 mount 和 umount命令在内的传统工具以及 /etc/vfstab 文件。有关传统挂载的更多信息,请参见传统挂载点

https://docs.oracle.com/cd/E37934_01/html/E36658/gaynd.html#gaztn

自动挂载点

  • 将 mountpoint 属性从 legacy 或 none 更改为特定路径时,ZFS 会自动挂载文件系统。

  • 如果 ZFS 正在管理文件系统,但该文件系统当前已取消挂载,并且 mountpoint 属性已更改,则文件系统将保持取消挂载状态。

mountpoint 属性不是 legacy 的所有文件系统都由 ZFS 来管理。在以下示例中,创建了一个挂载点由 ZFS 自动管理的文件系统:

# zfs create pool/filesystem
# zfs get mountpoint pool/filesystem
NAME PROPERTY VALUE SOURCE
pool/filesystem mountpoint /pool/filesystem default
# zfs get mounted pool/filesystem
NAME PROPERTY VALUE SOURCE
pool/filesystem mounted yes -

另外,也可按以下示例所示,显式设置 mountpoint 属性:

# zfs set mountpoint=/mnt pool/filesystem
# zfs get mountpoint pool/filesystem
NAME PROPERTY VALUE SOURCE
pool/filesystem mountpoint /mnt local
# zfs get mounted pool/filesystem
NAME PROPERTY VALUE SOURCE
pool/filesystem mounted yes -

mountpoint 属性更改时,文件系统将自动从旧挂载点取消挂载,并重新挂载到新挂载点。挂载点目录根据需要进行创建。如果 ZFS 由于文件系统正处于活动状态而无法将其取消挂载,则会报告错误,并需要强制进行手动取消挂载。

https://docs.oracle.com/cd/E37934_01/html/E36658/gaynd.html#gbala

存储池的缺省挂载点

创建池时,顶层文件系统的缺省挂载点是 /pool-name。此目录必须不存在或者为空。如果目录不存在,则会自动创建该目录。如果该目录为空,则根文件系统会挂载在现有目录的顶层。要使用不同的缺省挂载点创建池,请在 -zpool create 命令中使用 m 选项。例如,

# zpool create home c1t0d0
default mountpoint '/home' exists and is not empty
use '-m' option to provide a different default
# zpool create -m /export/zfs home c1t0d0

此命令会创建新池 home 和挂载点为 /export/zfs 的 home 文件系统。

有关挂载点的更多信息,请参见管理 ZFS 挂载点

https://docs.oracle.com/cd/E37934_01/html/E36658/gaypw.html#gbeef

solaris11 format zpool的更多相关文章

  1. Spring resource bundle多语言,单引号format异常

    Spring resource bundle多语言,单引号format异常 前言 十一假期被通知出现大bug,然后发现是多语言翻译问题.法语中有很多单引号,单引号在format的时候出现无法匹配问题. ...

  2. c# 字符串连接使用“+”和string.format格式化两种方式

    参考文章:http://www.liangshunet.com/ca/201303/218815742.htm 字符串之间的连接常用的两种是:“+”连接.string.format格式化连接.Stri ...

  3. PAT甲级 1001. A+B Format (20)

    题目原文: Calculate a + b and output the sum in standard format -- that is, the digits must be separated ...

  4. Conversion to Dalvik format failed: Unable to execute dex: Multiple dex files define ...

    Conversion to Dalvik format failed: Unable to execute dex: Multiple dex files define ... 这个错误是因为有两个相 ...

  5. 【转】string.Format对C#字符串格式化

    转自:http://blog.csdn.net/samsone/article/details/7556781 1.格式化货币(跟系统的环境有关,中文系统默认格式化人民币,英文系统格式化美元) str ...

  6. VBA 格式化字符串 - Format大全

    VBA 格式化字符串 VBA 的 Format 函数与工作表函数 TEXT 用法基本相同,但功能更加强大,许多格式只能用于VBA 的 Format 函数,而不能用于工作表函数 TEXT ,以下是本人归 ...

  7. [Erlang 0111] Erlang Abstract Format , Part 2

       上回书,我们说到飞天玉虎蒋伯芳来到蜈蚣岭,不是,重来,上回咱们说到可以在Erlang Shell里面手工构造,加载并调用一个模块.在那个demo里面,我把多个Form单独生成出来,最后放在一起做 ...

  8. [Erlang 0110] Erlang Abstract Format , Part 1

    Erlang Abstract Format并不难懂,只是枯燥一点罢了,如果把Abstract Format的文档翻译出来,其实就是Erlang教科书中语法入门的部分. Erlang Abstract ...

  9. C#中string.format用法详解

    C#中string.format用法详解 本文实例总结了C#中string.format用法.分享给大家供大家参考.具体分析如下: String.Format 方法的几种定义: String.Form ...

随机推荐

  1. prism App.config 配置

    <?xml version="1.0" encoding="utf-8" ?> <configuration> <configSe ...

  2. 使用apicloud开发移动端APP,IOS list页面滚动卡顿解决记录

    给内容容器添加样式:-webkit-overflow-scrolling:touch; -webkit-overflow-scrolling:属性控制元素在移动设备上是否使用滚动回弹效果. auto: ...

  3. mybatis 动态SQL .1

    MyBatis 的强大特性之一便是它的动态 SQL.如果你有使用 JDBC 或其它类似框架的经验,你就能体会到根据不同条件拼接 SQL 语句的痛苦.例如拼接时要确保不能忘记添加必要的空格,还要注意去掉 ...

  4. vsftp新建用户及目录时遇到的坑

    1.有关vsftp配置及用户权限设置,请参考: http://blog.sina.com.cn/s/blog_3edc5e2e0102vzv8.html 2.需求:公司另一部门要求单独建一目录,来存在 ...

  5. #Java学习之路——基础阶段二(第十三篇)

    我的学习阶段是跟着CZBK黑马的双源课程,学习目标以及博客是为了审查自己的学习情况,毕竟看一遍,敲一遍,和自己归纳总结一遍有着很大的区别,在此期间我会参杂Java疯狂讲义(第四版)里面的内容. 前言: ...

  6. Nginx的用途

    Nginx应该是现在最火的web和反向代理服务器,没有之一.她是一款诞生于俄罗斯的高性能web服务器,尤其在高并发情况下,相较Apache,有优异的表现. 那除了负载均衡,她还有什么其他的用途呢,下面 ...

  7. 从MAP角度理解神经网络训练过程中的正则化

    在前面的文章中,已经介绍了从有约束条件下的凸优化角度思考神经网络训练过程中的L2正则化,本次我们从最大后验概率点估计(MAP,maximum a posteriori point estimate)的 ...

  8. 微信小程序request请求封装,验签

    1/ 公共文件util添加 request请求 //简单封装请求 function request(params, path, isShowLoading = true, goBack = false ...

  9. CentOS7安装配置MariaDB(mysql)数据主从同步

    CentOS7安装MariaDB并配置主从同步 环境声明: 防火墙firewalld及SElinux均为关闭状态 主库节点:192.168.0.63 从库节点:192.168.0.64 配置主库节点: ...

  10. spring boot-6.profile 多环境支持

    在正式项目中一般都会区分多个环境,一般至少分为开发环境,测试生产环境,生产环境,实际可能会有更加精细的区分,针对不同的环境,项目的配置可能需要切换,spring boot 提供了很方便的环境切换方式. ...