hns - 日記自動生成システム - Version 2.19.9

先月 2001年06月 来月
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
Namazu for hns による簡易全文検索
詳しくは 詳細指定/ヘルプを参照して下さい
検索式:

2001年06月23日() 旧暦 [n年日記]

#1 [NetBSD] sysinst で label 読出

朝 4:40 から目がさめてしまった。で、 sysinst/arch/md.c 変更中 Segmentation Fault。修行が足りない。
  l = *disklabel;
これでは写せないか。

取敢えず 既存の区画内容を見るまでは出来た:

しかし install.c の中で、
105   if (md_pre_disklabel() != 0)
106           return;
107 
108   if (write_disklabel() != 0)
109           return;
110   
111   if (md_post_disklabel() != 0)
112           return;
というところがあって、write_disklabel() は disks.c の中で次のように書いてある。
234 int
235 write_disklabel (void)
236 {
237 
238 #ifdef DISKLABEL_CMD
239         /* disklabel the disk */
240         return run_prog(RUN_DISPLAY, MSG_cmdfail,
241             "%s %s %s", DISKLABEL_CMD, diskdev, bsddiskname);
242 #endif
243         return 0;
244 }
しかし、同じ macppc でも Apple Partition Map の時は書いて欲しくないし、 NetBSD label の時は書いて欲しい

/usr/src/sbin/disklabel/disklabel.c より。:

if (lp->d_bbsize == 0) {
        warnx("boot block size %d", lp->d_bbsize);
        errors++;
} else if (lp->d_bbsize % lp->d_secsize)
        warnx("warning, boot block size %% sector-size != 0");
if (lp->d_sbsize == 0) {
        warnx("super block size %d", lp->d_sbsize);
        errors++;
} else if (lp->d_sbsize % lp->d_secsize)
        warnx("warning, super block size %% sector-size != 0");
Apple partition map の時には
disklabel: boot block size 0
disklabel: super block size 0
と表示される



最近の日記
2024年05月05日
Windows 10 version
serial connection
bc bench
2024年05月04日
Trial on 10.99.10
another version (later trial) to succeed
2024年04月29日
dkim
2024年03月10日
停電 (瞬電)
2024年03月03日
the second try on bare-metal
useradd
以上、1 日分です。
タイトル一覧
カテゴリ分類
Powered by hns-2.19.9, HyperNikkiSystem Project

Count.cgi (since 2000/02/05)