Subject: Re: undoing chflags schg ?
To: None <y0001006@ws.rz.tu-bs.de>
From: Andrew Brown <codewarrior@daemon.org>
List: netbsd-help
Date: 04/17/1997 11:24:23
>> >The question: How do I undo the above operation, if I try
>> >"chflags noschg /netbsd" I simply get "Permission denied", 
>> >with rm it's the same.
>> 
>> kill -1 1 (to tell init to take you back to single-user/securelevel 0)
>> and then you can remove the flag.
>
>Thanks a lot, I'll try that. I already tried a single-user *startup*, 
>but that only mounts the filesystem read-only (hmm).
>My Unix book (unfortunately about SVR4) says you can use shutdown 
>to switch security level, but the BSD one doesn't support this.

going from multi-user back to single user (ala kill -1 1) leaves
everything mounted read/write.  if you wanna fix it when *booting*
single user, then you will need to "mount -u /" to remount /
read/write.

the srv4 shutdown command is *quite* different from the bsd one.  they
have a severely different idea of run levels.  i suggest you go look
for the 4.4bsd book by mckusick et al.

>BTW: Is chflags schg MEANT to be irreversible in normal (root) mode ?

yes, in any securelevel above zero.

-- 
|-----< "CODE WARRIOR" >-----|
andrew@echonyc.com (TheMan)        * "ah!  i see you have the internet
codewarrior@daemon.org                               that goes *ping*!"
warfare@graffiti.com      * "information is power -- share the wealth."