+ -
当前位置:首页 → 问答吧 → 最近本论坛的兄弟好像是祸事连连啊

最近本论坛的兄弟好像是祸事连连啊

时间:2007-08-31

来源:互联网

一个rm -fr /*,一个gui installer干掉了硬盘分区。
还好退出“root敢死队”好久了,但是前几天,升级baselayout后,由于不支持lvm2,又降级回来,来回几次后导致init错乱,虽然可以勉强进入系统,还是没办法修复init(人品问题吧)。好不容易构建起来一个新系统,结果emerge symlinks后,在" /" 下执行cleanliks之后(感觉不对劲后ctrl+c终止),就怎么也不能用ctrl+alt+f1...切换终端了(reboot的过程似乎可以切换) 很是郁闷! “symlinks”到底是怎样一个软件包啊?它直接干掉了/etc/和其他目录几个软连接!不是删除无效连接吗?记得以前使用很正常的,难道又是人品问题?现在的问题是怎样修复。。。请指教。多谢了!

作者: schoolwind   发布时间: 2007-08-31

是删除无效连接的。
有个问题是要注意的与系统有关的分区要正常mount上,比如我的/usr/portage是单独分区的,平时是不mount的,这是使用symlinks就会把/etc/make.profile删除,因为/etc/make.profile是连接/usr/portage/profiles/default-linux/x86/2007.0/desktop,这时就是无效连接了。

作者: zhoukb   发布时间: 2007-08-31

引用:
作者: zhoukb
是删除无效连接的。
是的!"/etc/make.profile"就是其中之一。但是我的/usr/portage也是单独分区并且已经挂载上了啊。还有它还删除了/usr/src/linux的软连接(这是我可以明确确定的),其他我不知它删除了哪些关键的连接。鉴于我个人目前的人品问题,现在我已经unemerge了。关于不能用ctrl + alt + fx切换到控制台,我搜了一下好像是splash的问题。。。难道只有禁用splash themes?

作者: schoolwind   发布时间: 2007-08-31

我想问一下你的baselayout升级到哪个版本的时候不能用lvm2了,具体是出现什么问题?

因为我现在系统就是用的lvm2,我想心里有个底,免得某次升级就把系统搞崩了。另外,如果可以把这个bug搞定免得今后别人再遇到这个问题不是更好。

作者: meteo   发布时间: 2007-08-31

回楼上,baselayout 2。是被mask了的,听说用C重写的,速度更快,radhat的东西。前几天没事瞎折腾,其他init脚本迁移都正常,速度似乎更快了,但是找不到lvm2分区,我想并不是不支持lvm,可能gentoo的开发者还没完成移植而已。

作者: schoolwind   发布时间: 2007-08-31

不能用ctrl+alt+fx切换的问题,是splash theme的bug?重新emerge 相关的几个包就正常了。现在没事正在折腾内核,有个slub的东西(内存管理),听说可以提升内存效率和性能。

作者: schoolwind   发布时间: 2007-08-31

引用:
作者: schoolwind
回楼上,baselayout 2。是被mask了的,听说用C重写的,速度更快,radhat的东西。前几天没事瞎折腾,其他init脚本迁移都正常,速度似乎更快了,但是找不到lvm2分区,我想并不是不支持lvm,可能gentoo的开发者还没完成移植而已。
我看了一下,lvm2的启动和关闭是加在/lib/rcscripts/addons/目录下,有两个脚本文件lvm-start.sh和lvm-stop.sh,没准baselayout2.0改变了这种机制

不管怎么说,我对系统的升级还是比较保守,关键字用amd64(过去32位系统用x86),遇到需要的包再用~amd64,这样很少出问题。

作者: meteo   发布时间: 2007-08-31

baselayout2是支持lvm2的,楼上的先把lvm加入boot runlevel
代码:
#rc-update add lvm boot
代码:
 # qlop -Hl baselayout
Mon Apr 23 17:23:29 2007 >>> sys-apps/baselayout-1.12.9-r2
Mon Apr 23 21:59:32 2007 >>> sys-apps/baselayout-1.12.10-r3
Sat Apr 28 23:55:54 2007 >>> sys-apps/baselayout-2.0.0_alpha1
Sun Apr 29 07:02:06 2007 >>> sys-apps/baselayout-2.0.0_alpha1
Sun Apr 29 07:24:08 2007 >>> sys-apps/baselayout-1.12.10-r3
Sat Apr 28 23:47:47 2007 >>> sys-apps/baselayout-2.0.0_alpha1
Sat Apr 28 23:48:42 2007 >>> sys-apps/baselayout-2.0.0_alpha1
Thu May 3 17:40:44 2007 >>> sys-apps/baselayout-1.12.10-r3
Sat May 5 07:31:54 2007 >>> sys-apps/baselayout-2.0.0_alpha1
Tue May 8 02:29:37 2007 >>> sys-apps/baselayout-2.0.0_alpha2
Thu May 10 02:33:09 2007 >>> sys-apps/baselayout-2.0.0_alpha2-r1
Mon May 14 08:32:35 2007 >>> sys-apps/baselayout-1.12.10-r4
Mon May 14 08:50:03 2007 >>> sys-apps/baselayout-2.0.0_alpha2-r1
Wed May 16 03:54:46 2007 >>> sys-apps/baselayout-2.0.0_alpha3
Fri Jun 1 01:10:40 2007 >>> sys-apps/baselayout-2.0.0_alpha3-r1
Mon Aug 6 23:01:45 2007 >>> sys-apps/baselayout-2.0.0_rc2-r1
Thu Aug 23 16:11:22 2007 >>> sys-apps/baselayout-2.0.0_rc3-r1
代码:
[14:32:23 polaris] ~ # lvdisplay 
 --- Logical volume ---
 LV Name /dev/vg_gentoo/usr
 VG Name vg_gentoo
 LV UUID w6FIDL-SIoW-OfB8-q1A7-Rbl6-7z4q-Gnbn22
 LV Write Access read/write
 LV Status available
 # open 2
 LV Size 6.00 GB
 Current LE 1536
 Segments 2
 Allocation inherit
 Read ahead sectors 0
 Block device 254:0
 
 --- Logical volume ---
 LV Name /dev/vg_gentoo/opt
 VG Name vg_gentoo
 LV UUID FoJqyQ-1PgE-iOGO-DaPe-qayN-gipb-omWRTz
 LV Write Access read/write
 LV Status available
 # open 2
 LV Size 5.00 GB
 Current LE 1280
 Segments 1
 Allocation inherit
 Read ahead sectors 0
 Block device 254:1
 
 --- Logical volume ---
 LV Name /dev/vg_gentoo/var
 VG Name vg_gentoo
 LV UUID BFufMG-9TiK-FTM3-JmEo-4XQ8-qf4Y-lH0niR
 LV Write Access read/write
 LV Status available
 # open 2
 LV Size 1.00 GB
 Current LE 256
 Segments 1
 Allocation inherit
 Read ahead sectors 0
 Block device 254:2
 
 --- Logical volume ---
 LV Name /dev/vg_gentoo/portage
 VG Name vg_gentoo
 LV UUID 0M0Uvd-9IRq-7yb0-cTb4-a6jW-M1h6-bK9Zpw
 LV Write Access read/write
 LV Status available
 # open 2
 LV Size 512.00 MB
 Current LE 128
 Segments 1
 Allocation inherit
 Read ahead sectors 0
 Block device 254:3
 
 --- Logical volume ---
 LV Name /dev/vg_gentoo/distfiles
 VG Name vg_gentoo
 LV UUID VcsTHI-Fwe3-ZD48-6Wzc-RM45-NYm6-NIs7M8
 LV Write Access read/write
 LV Status available
 # open 2
 LV Size 3.00 GB
 Current LE 768
 Segments 1
 Allocation inherit
 Read ahead sectors 0
 Block device 254:4
 
 --- Logical volume ---
 LV Name /dev/vg_gentoo/vartmp
 VG Name vg_gentoo
 LV UUID 3Ccn3L-onKP-U1V4-Aw9T-Mh76-ec3M-5UKp0P
 LV Write Access read/write
 LV Status available
 # open 2
 LV Size 5.00 GB
 Current LE 1280
 Segments 1
 Allocation inherit
 Read ahead sectors 0
 Block device 254:5
只不过root分区不是lvm2的,

作者: Blahster   发布时间: 2007-08-31

呵呵,这样我就放心了,我现在还没用baselayout2

我的root分区也是lvm2的,具体说我的root分区是先raid0,再lvm,之所以这样是利用lvm2的快照功能方便备份

具体实现是把dmraid的支持加入了lvm2create_initrd,有空我再贴上来吧
引用:
作者: Blahster
baselayout2是支持lvm2的,楼上的先把lvm加入boot runlevel
代码:
#rc-update add lvm boot
代码:
 # qlop -Hl baselayout
Mon Apr 23 17:23:29 2007 >>> sys-apps/baselayout-1.12.9-r2
Mon Apr 23 21:59:32 2007 >>> sys-apps/baselayout-1.12.10-r3
Sat Apr 28 23:55:54 2007 >>> sys-apps/baselayout-2.0.0_alpha1
Sun Apr 29 07:02:06 2007 >>> sys-apps/baselayout-2.0.0_alpha1
Sun Apr 29 07:24:08 2007 >>> sys-apps/baselayout-1.12.10-r3
Sat Apr 28 23:47:47 2007 >>> sys-apps/baselayout-2.0.0_alpha1
Sat Apr 28 23:48:42 2007 >>> sys-apps/baselayout-2.0.0_alpha1
Thu May 3 17:40:44 2007 >>> sys-apps/baselayout-1.12.10-r3
Sat May 5 07:31:54 2007 >>> sys-apps/baselayout-2.0.0_alpha1
Tue May 8 02:29:37 2007 >>> sys-apps/baselayout-2.0.0_alpha2
Thu May 10 02:33:09 2007 >>> sys-apps/baselayout-2.0.0_alpha2-r1
Mon May 14 08:32:35 2007 >>> sys-apps/baselayout-1.12.10-r4
Mon May 14 08:50:03 2007 >>> sys-apps/baselayout-2.0.0_alpha2-r1
Wed May 16 03:54:46 2007 >>> sys-apps/baselayout-2.0.0_alpha3
Fri Jun 1 01:10:40 2007 >>> sys-apps/baselayout-2.0.0_alpha3-r1
Mon Aug 6 23:01:45 2007 >>> sys-apps/baselayout-2.0.0_rc2-r1
Thu Aug 23 16:11:22 2007 >>> sys-apps/baselayout-2.0.0_rc3-r1
代码:
[14:32:23 polaris] ~ # lvdisplay 
 --- Logical volume ---
 LV Name /dev/vg_gentoo/usr
 VG Name vg_gentoo
 LV UUID w6FIDL-SIoW-OfB8-q1A7-Rbl6-7z4q-Gnbn22
 LV Write Access read/write
 LV Status available
 # open 2
 LV Size 6.00 GB
 Current LE 1536
 Segments 2
 Allocation inherit
 Read ahead sectors 0
 Block device 254:0
 
 --- Logical volume ---
 LV Name /dev/vg_gentoo/opt
 VG Name vg_gentoo
 LV UUID FoJqyQ-1PgE-iOGO-DaPe-qayN-gipb-omWRTz
 LV Write Access read/write
 LV Status available
 # open 2
 LV Size 5.00 GB
 Current LE 1280
 Segments 1
 Allocation inherit
 Read ahead sectors 0
 Block device 254:1
 
 --- Logical volume ---
 LV Name /dev/vg_gentoo/var
 VG Name vg_gentoo
 LV UUID BFufMG-9TiK-FTM3-JmEo-4XQ8-qf4Y-lH0niR
 LV Write Access read/write
 LV Status available
 # open 2
 LV Size 1.00 GB
 Current LE 256
 Segments 1
 Allocation inherit
 Read ahead sectors 0
 Block device 254:2
 
 --- Logical volume ---
 LV Name /dev/vg_gentoo/portage
 VG Name vg_gentoo
 LV UUID 0M0Uvd-9IRq-7yb0-cTb4-a6jW-M1h6-bK9Zpw
 LV Write Access read/write
 LV Status available
 # open 2
 LV Size 512.00 MB
 Current LE 128
 Segments 1
 Allocation inherit
 Read ahead sectors 0
 Block device 254:3
 
 --- Logical volume ---
 LV Name /dev/vg_gentoo/distfiles
 VG Name vg_gentoo
 LV UUID VcsTHI-Fwe3-ZD48-6Wzc-RM45-NYm6-NIs7M8
 LV Write Access read/write
 LV Status available
 # open 2
 LV Size 3.00 GB
 Current LE 768
 Segments 1
 Allocation inherit
 Read ahead sectors 0
 Block device 254:4
 
 --- Logical volume ---
 LV Name /dev/vg_gentoo/vartmp
 VG Name vg_gentoo
 LV UUID 3Ccn3L-onKP-U1V4-Aw9T-Mh76-ec3M-5UKp0P
 LV Write Access read/write
 LV Status available
 # open 2
 LV Size 5.00 GB
 Current LE 1280
 Segments 1
 Allocation inherit
 Read ahead sectors 0
 Block device 254:5
只不过root分区不是lvm2的,

作者: meteo   发布时间: 2007-08-31

受教了。顺便请教上面各位,lvm启动脚本是用 /lib/rcscripts/addons下的吗,还是要自己写?如果有现成的不妨贴一下,谢谢。

作者: schoolwind   发布时间: 2007-08-31

引用:
作者: schoolwind
受教了。顺便请教上面各位,lvm启动脚本是用 /lib/rcscripts/addons下的吗,还是要自己写?如果有现成的不妨贴一下,谢谢。
不需要自己写,如果是baselayout2,你安装lvm2后直接rc-update add lvm boot就可以
如果不是baselayout2,安装lvm2后,几个脚本会自动装到/lib/rcscripts/addons/目录下。不需要你自己折腾

作者: meteo   发布时间: 2007-09-01

baselayout是gentoo特有的
baselayout-2是gentoo开发者自己写的

作者: zhllg   发布时间: 2007-09-01

引用:
作者: zhllg
baselayout是gentoo特有的
baselayout-2是gentoo开发者自己写的
多谢版主指正。我好像是在源码目录下看到有redhat的字样。。。

作者: schoolwind   发布时间: 2007-09-01

http://roy.marples.name/node/299
http://roy.marples.name/node/300
http://roy.marples.name/node/302

作者: zhllg   发布时间: 2007-09-01

热门下载

更多