Search the web
Sign In
New User? Sign Up
FreeBSD-rc · Improving FreeBSD startup scripts
? Already a member? Sign in to Yahoo!

Yahoo! Groups Tips

Did you know...
Hear how Yahoo! Groups has changed the lives of others. Take me there.

Best of Y! Groups

   Check them out and nominate your group.
Having problems with message search? Fill out this form to ensure your group is one of the first to be migrated to the new message search system.

Messages

  Messages Help
Advanced
Messages 358 - 729 of 729   Newest  |  < Newer  |  Older >  |  Oldest
Messages: Show Message Summaries   (Group by Topic) Sort by Date v  
#729 From: "Doug" <DougB@...>
Date: Mon Mar 15, 2004 12:41 am
Subject: New FreeBSD list created
domain_name_...
Offline Offline
Send Email Send Email
 
Howdy,

As promised, the new @freebsd version of this list has been created.
Please note, the delay on this point was entirely mine, as it took me
longer than hoped to answer questions from the postmaster.

I'm purposely avoiding putting the subscribe instructions in this
e-mail because looking over the list of members I think there are more
than one suspicious e-mail addresses. :-/  However, if you are a
legitimate user and can't figure out how to subscribe, feel free to
mail me.

Enjoy,

Doug

#727 From: Mike Makonnen <mtm@...>
Date: Wed Mar 3, 2004 2:51 pm
Subject: patch to shut up ps(1) errors - Checked by AntiVir DEMO version -
mike_makonnen
Offline Offline
Send Email Send Email
 
Hi Luke, folks,

The attached patch shuts up ps(1) when the program we're looking for
does not exist. The error message is something along the lines of:
ps: kvm_getprocs: no such process
It's not critical, but it's annoying :(
I don't know if NetBSD ps(1) does the same thing, but
even if it doesn't it should be harmless.

Cheers.
--
Mike Makonnen  | GPG-KEY: http://www.identd.net/~mtm/mtm.asc
mtm@... | Fingerprint: AC7B 5672 2D11 F4D0 EBF8  5279 5359 2B82 7CD4 1F55
mtm@...| FreeBSD - Unleash the Daemon !
Index: etc/rc.subr
===================================================================
RCS file: /home/ncvs/src/etc/rc.subr,v
retrieving revision 1.24
diff -u -r1.24 rc.subr
--- etc/rc.subr 27 Feb 2004 09:58:50 -0000 1.24
+++ etc/rc.subr 3 Mar 2004 17:09:08 -0000
@@ -267,7 +267,7 @@
 	 fi

 	 _proccheck='
-  ps -o "pid,command" '"$_psargs"' |
+  ps 2>/dev/null -o "pid,command" '"$_psargs"' |
 		 while read _npid '"$_fp_args"'; do
 			 case "$_npid" in
 			     PID)

#726 From: Mike Makonnen <mtm@...>
Date: Wed Mar 3, 2004 3:07 pm
Subject: Fixing faststop - Checked by AntiVir DEMO version -
mike_makonnen
Offline Offline
Send Email Send Email
 
Hi folks,

I'm not sure if the fast prefix was intended to also work with
the stop command, but I think it should. The reason is because
most applications don't clean up their pid file when they shut
down, so if I shutdown(8) from single-user I get a lot of:
xxx not running? (check pidfile)
which is annoying and makes the os seem "unpolished."
So, the attached patch tries to fix that by making the stop
command simply exit (withoug displaying any messages) if
it tried looking for a running program and could not find it,
and rc_fast is set.

Note, that in order to make it work I had to change the
way the _pidcmd is evaluated. It is evaluated unconditionally
now. The check for the existence of rc_fast happens later for
the start command.

Note that you may still get that error for ports because they
use a copy of rc.subr under /usr/local and not the base system
rc.subr (That's another problem, but if you follow -arch you
know I'm trying to get that fixed as well).

Cheers.
--
Mike Makonnen  | GPG-KEY: http://www.identd.net/~mtm/mtm.asc
mtm@... | Fingerprint: AC7B 5672 2D11 F4D0 EBF8  5279 5359 2B82 7CD4 1F55
mtm@...| FreeBSD - Unleash the Daemon !
Index: etc/rc.shutdown
===================================================================
RCS file: /home/ncvs/src/etc/rc.shutdown,v
retrieving revision 1.25
diff -u -r1.25 rc.shutdown
--- etc/rc.shutdown 8 Jul 2003 02:52:14 -0000 1.25
+++ etc/rc.shutdown 3 Mar 2004 13:31:45 -0000
@@ -85,8 +85,8 @@
  files=`eval grep -l \'^# KEYWORD:.*FreeBSD\' \`rcorder -k shutdown /etc/rc.d/*
2>/dev/null\``

  for _rc_elem in `reverse_list $files`; do
- debug "run_rc_script $_rc_elem stop"
- run_rc_script $_rc_elem stop
+ debug "run_rc_script $_rc_elem faststop"
+ run_rc_script $_rc_elem faststop
  done

  # Terminate the background watchdog timer (if it is running)
Index: etc/rc.subr
===================================================================
RCS file: /home/ncvs/src/etc/rc.subr,v
retrieving revision 1.24
diff -u -r1.24 rc.subr
--- etc/rc.subr 27 Feb 2004 09:58:50 -0000 1.24
+++ etc/rc.subr 3 Mar 2004 17:02:28 -0000
@@ -493,7 +493,7 @@
 	 _procname=${procname:-${command}}

 					 # setup pid check command if not fast
- if [ -z "$rc_fast" -a -n "$_procname" ]; then
+ if [ -n "$_procname" ]; then
 		 if [ -n "$pidfile" ]; then
 			 _pidcmd='rc_pid=$(check_pidfile '"$pidfile $_procname
$command_interpreter"')'
 		 else
@@ -586,7 +586,7 @@
 			 ;;

 		 start)
- 	 if [ -n "$rc_pid" ]; then
+ 	 if [ -z "$rc_fast" -a -n "$rc_pid" ]; then
 				 echo "${name} already running? (pid=$rc_pid)."
 				 exit 1
 			 fi
@@ -671,6 +671,7 @@

 		 stop)
 			 if [ -z "$rc_pid" ]; then
+ 		 [ -n "$rc_fast" ] && exit 0
 				 if [ -n "$pidfile" ]; then
 					 echo \
 				     "${name} not running? (check $pidfile)."

#725 From: Doug Barton <DougB@...>
Date: Tue Feb 17, 2004 11:54 pm
Subject: Re: Change to list posting policy
domain_name_...
Offline Offline
Send Email Send Email
 
On Wed, 18 Feb 2004, Simon L. Nielsen wrote:

> Now that the FreeBSD mail system is back to running normally for the
> mailing lists how about getting this list moved ?

It's in process. I tried a couple mails to the list over the weekend and
got rebuffed by the "post as subscriber" filter. :)

Doug

--

     This .signature sanitized for your protection

#723 From: Brooks Davis <brooks@...>
Date: Fri Feb 6, 2004 4:42 pm
Subject: Re: Re: [spam] rc.d/ttys
brdavis
Offline Offline
Send Email Send Email
 
On Fri, Feb 06, 2004 at 06:30:40PM +0300, Mike Makonnen wrote:
> [ phk cc-ed ]
>
> On Thu, Feb 05, 2004 at 10:14:58AM -0800, Brooks Davis wrote:
>
> > Date: Thu, 5 Feb 2004 10:14:58 -0800
> > To: freebsd-rc@yahoogroups.com
> > From: Brooks Davis <brooks@...>
> > Subject: [FreeBSD-rc] rc.d/ttys
> > User-Agent: Mutt/1.5.4i
> > Mailing-List: list FreeBSD-rc@yahoogroups.com; contact
FreeBSD-rc-owner@yahoogroups.com
> >
> > I noticed that rc.d/ttys has a circular dependency caused by requiring
> > mountcritremote.  I can't figure out why you would need that, any ideas?
>
> I don't see any circular dependency, and rcorder(8) backs me up :-)
> What do you think is circular ?

rcorder was bitching to me.  I wonder if I added something to cause it.
I'm in the process of rewriting the diskless script to make it support
read-only roots better and thus I've been moving a lot of things around.

-- Brooks

--
Any statement of the form "X is the one, true Y" is FALSE.
PGP fingerprint 655D 519C 26A7 82E7 2529  9BF0 5D8E 8BE9 F238 1AD4

#722 From: Mike Makonnen <mtm@...>
Date: Fri Feb 6, 2004 3:30 pm
Subject: Re: [spam] rc.d/ttys
mike_makonnen
Offline Offline
Send Email Send Email
 
[ phk cc-ed ]

On Thu, Feb 05, 2004 at 10:14:58AM -0800, Brooks Davis wrote:

> Date: Thu, 5 Feb 2004 10:14:58 -0800
> To: freebsd-rc@yahoogroups.com
> From: Brooks Davis <brooks@...>
> Subject: [FreeBSD-rc] rc.d/ttys
> User-Agent: Mutt/1.5.4i
> Mailing-List: list FreeBSD-rc@yahoogroups.com; contact
FreeBSD-rc-owner@yahoogroups.com
>
> I noticed that rc.d/ttys has a circular dependency caused by requiring
> mountcritremote.  I can't figure out why you would need that, any ideas?

I don't see any circular dependency, and rcorder(8) backs me up :-)
What do you think is circular ?

> Also, the whole script seems pointless since devfs is manditory.  Do we
> need it at all?

I think you're right. Poul-Henning, what do you think ?

Cheers.
--
Mike Makonnen  | GPG-KEY: http://www.identd.net/~mtm/mtm.asc
mtm@... | Fingerprint: 00E8 61BC 0D75 7FFB E4D3  6BF1 B239 D010 3215 D418
mtm@...| FreeBSD - Unleash the Daemon !

#721 From: Brooks Davis <brooks@...>
Date: Thu Feb 5, 2004 6:56 pm
Subject: broken spam filters.
brdavis
Offline Offline
Send Email Send Email
 
Wow, this list software is f-ing worthless.  I get spam all the time
from this list without any tagging, but a perfectly good message
with a valid digital signature is tagged as spam.

Please move this list to freebsd.org.

-- Brooks

On Thu, Feb 05, 2004 at 10:14:58AM -0800, Brooks Davis wrote:
> ------------------------------------------------------------------------
> Yahoo! Groups SpamGuard has detected that the attached message to the
> group FreeBSD-rc is likely to be spam.  For more information
> about SpamGuard, please visit our help pages:
> http://groups.yahoo.com/local/spamguard.html
> ------------------------------------------------------------------------
>

> From: Brooks Davis <brooks@...>
> Date: Thu, 5 Feb 2004 10:14:58 -0800
> To: freebsd-rc@yahoogroups.com
> Subject: [FreeBSD-rc] rc.d/ttys
>
> I noticed that rc.d/ttys has a circular dependency caused by requiring
> mountcritremote.  I can't figure out why you would need that, any ideas?
> Also, the whole script seems pointless since devfs is manditory.  Do we
> need it at all?
>
> -- Brooks
>
> --
> Any statement of the form "X is the one, true Y" is FALSE.
> PGP fingerprint 655D 519C 26A7 82E7 2529  9BF0 5D8E 8BE9 F238 1AD4



--
Any statement of the form "X is the one, true Y" is FALSE.
PGP fingerprint 655D 519C 26A7 82E7 2529  9BF0 5D8E 8BE9 F238 1AD4

#720 From: Brooks Davis <brooks@...>
Date: Thu Feb 5, 2004 6:14 pm
Subject: rc.d/ttys
brdavis
Offline Offline
Send Email Send Email
 
I noticed that rc.d/ttys has a circular dependency caused by requiring
mountcritremote.  I can't figure out why you would need that, any ideas?
Also, the whole script seems pointless since devfs is manditory.  Do we
need it at all?

-- Brooks

--
Any statement of the form "X is the one, true Y" is FALSE.
PGP fingerprint 655D 519C 26A7 82E7 2529  9BF0 5D8E 8BE9 F238 1AD4

#719 From: Mike Makonnen <mtm@...>
Date: Fri Jan 30, 2004 3:23 pm
Subject: Re: Change to list posting policy
mike_makonnen
Offline Offline
Send Email Send Email
 
On Fri, Jan 30, 2004 at 01:02:14PM -0000, Doug wrote:
> Guys,
>
> All but 2 of the last 100 messages to this list were spam, and that
> trend is pretty consistent over time. Therefore I've changed the
> policy of the list to posting by members only as a short term solution.
>
> Longer term solutions include asking postmaster@... for an
> @freebsd.org list again, and/or adding moderators to this list, or the
> new list if we decide that's the way to go. Realistically I can't do
> the moderation of this list justice on my own, but if there were 3 or
> 4 people available to help, I think it would easily get the job done.
>
> What do you think?

I think we should move to a freebsd.org hosted list.

I also prefer a non-moderated list but I won't argue if people want
otherwise.

Cheers.
--
Mike Makonnen  | GPG-KEY: http://www.identd.net/~mtm/mtm.asc
mtm@... | Fingerprint: 00E8 61BC 0D75 7FFB E4D3  6BF1 B239 D010 3215 D418
mtm@...| FreeBSD - Unleash the Daemon !

#718 From: "Doug" <DougB@...>
Date: Fri Jan 30, 2004 1:02 pm
Subject: Change to list posting policy
domain_name_...
Offline Offline
Send Email Send Email
 
Guys,

All but 2 of the last 100 messages to this list were spam, and that
trend is pretty consistent over time. Therefore I've changed the
policy of the list to posting by members only as a short term solution.

Longer term solutions include asking postmaster@... for an
@freebsd.org list again, and/or adding moderators to this list, or the
new list if we decide that's the way to go. Realistically I can't do
the moderation of this list justice on my own, but if there were 3 or
4 people available to help, I think it would easily get the job done.

What do you think?

Doug

#659 From: "Simon L. Nielsen" <simon@...>
Date: Sat Jan 17, 2004 5:39 pm
Subject: Enhancement to gbde rc.d script
simon@...
Send Email Send Email
 
Hello

I have enhanced the gbde rc.d script a bit, so it asks the user X times
(normally 3) for the pass-phrase.  I have also added support for having
the lockfiles in another other directories than /etc.  Both features are
documented, and the existing feature of specifying the exact filename of
a lockfile is also documented in this patch.

Comments, or, even better, approval for me to commit it from a src
committer would be great :-).

--
Simon L. Nielsen
FreeBSD Documentation Team
Index: etc/rc.d/gbde
===================================================================
RCS file: /home/ncvs/src/etc/rc.d/gbde,v
retrieving revision 1.1
diff -u -r1.1 gbde
--- etc/rc.d/gbde 17 Jun 2003 02:56:29 -0000 1.1
+++ etc/rc.d/gbde 17 Jan 2004 17:09:14 -0000
@@ -72,10 +72,20 @@
 	 for device in $gbde_devices; do
 		 parentdev=${device%.bde}
 		 parent=${parentdev#/dev/}
-  eval "lock=\${gbde_lock_${parent}-\"/etc/${parent}.lock\"}"
-  if [ -e $lock ]; then
+  eval "lock=\${gbde_lock_${parent}-\"${gbde_lockdir}/${parent}.lock\"}"
+  if [ -e ${lock} -a ! -e ${device} ]; then
 			 echo "Configuring Disk Encryption for ${device}."
- 	 gbde attach ${parentdev} -l ${lock}
+
+ 	 count=1
+ 	 while [ ${count} -le ${gbde_attach_attempts} ]; do
+ 		 gbde attach ${parentdev} -l ${lock}
+ 		 if [ -e ${device} ]; then
+ 			 break
+ 		 fi
+ 		 echo "Attach failed; attempt ${count} of ${gbde_attach_attempts}."
+ 		 count=$((${count} + 1))
+ 	 done
+
 		 fi
 	 done
  }
Index: etc/defaults/rc.conf
===================================================================
RCS file: /home/ncvs/src/etc/defaults/rc.conf,v
retrieving revision 1.195
diff -u -r1.195 rc.conf
--- etc/defaults/rc.conf 25 Dec 2003 23:29:19 -0000 1.195
+++ etc/defaults/rc.conf 17 Jan 2004 17:29:15 -0000
@@ -45,6 +45,8 @@
  # Experimental - test before enabling
  gbde_autoattach_all="NO" # YES automatically mounts gbde devices from fstab
  gbde_devices="NO"  # Devices to automatically attach (list, or AUTO)
+gbde_attach_attempts="3" # Number of times to attempt attaching gbde devices.
+gbde_lockdir="/etc" # Where to look for gbde lockfiles.

  fsck_y_enable="NO" # Set to YES to do fsck -y if the initial preen fails.
  background_fsck="YES" # Attempt to run fsck in the background where possible.
Index: share/man/man5/rc.conf.5
===================================================================
RCS file: /home/ncvs/src/share/man/man5/rc.conf.5,v
retrieving revision 1.203
diff -u -r1.203 rc.conf.5
--- share/man/man5/rc.conf.5 26 Dec 2003 03:41:27 -0000 1.203
+++ share/man/man5/rc.conf.5 17 Jan 2004 17:29:49 -0000
@@ -922,13 +922,40 @@
  If set to
  .Dq Li YES ,
  .Pa /etc/rc.d/gbde
-will attempt to automatically initialize your .bde devices in
+will attempt to automatically initialize your
+.Xr gbde 4
+devices in
  .Pa /etc/fstab .
  .It Va gbde_devices
  .Pq Vt str
  List the devices that the script should try to attach,
  or
  .Dq Li AUTO .
+.It Va gbde_lockdir
+.Pq Vt str
+The directory where the
+.Xr gbde 4
+lockfiles are located.
+The default lockfile directory is
+.Pa /etc .
+.Pp
+The lockfile for each individual
+.Xr gbde 4
+device can be overridden by setting the variable
+.Va gbde_lock_ Ns Aq Ar device ,
+where
+.Ar device
+is the encrypted device without the
+.Dq Pa /dev/
+and
+.Dq Pa .bde
+parts.
+.It Va gbde_attach_attempts
+.Pq Vt int
+Number of times to attempt attaching to a
+.Xr gbde 4
+device, i.e. how many times the user is asked for the pass-phrase.
+Default is 3.
  .It Va fsck_y_enable
  .Pq Vt bool
  If set to

#611 From: Mike Makonnen <mtm@...>
Date: Tue Jan 6, 2004 2:57 pm
Subject: Re: Re: cvs commit: src/etc/rc.d motd
mike_makonnen
Offline Offline
Send Email Send Email
 
On Tue, Jan 06, 2004 at 12:35:35PM +1100, Luke Mewburn wrote:
> On Mon, Dec 01, 2003 at 02:30:37PM +0300, Mike Makonnen wrote:
>   | Does this mean we should remove the rest of the compatibility stuff
>   | in other scripts? As you say, the NetBSD folks don't seem interested
>   | in our changes. We originally had that compatibility stuff because
>   | we expected to iron them out with NetBSD, but it's been a full year
>   | since we did this and several attempts to get the NetBSD folks interested
>   | have failed. Plus, it just makes the affected scripts more cluttered
>   | and confusing.
>
> FWIW; whilst NetBSD is unlikely to share the same /etc/rc.d/* scripts
> with FreeBSD (10 years of feature skew between our projects),

Ok, cool. That'll make rc.d much cleaner.

> maintaining compatibility in rc.subr(8) and in the "end user experience"
> is useful.

As for rc.subr(8) I tried to interest
you in a small patch once but it never got anywhere (I don't recall the
reason). It would be nice if we could maintain compatibility, but the burden
can't be on us (FreeBSD) to do all the work.

Cheers.
--
Mike Makonnen  | GPG-KEY: http://www.identd.net/~mtm/mtm.asc
mtm@... | Fingerprint: 00E8 61BC 0D75 7FFB E4D3  6BF1 B239 D010 3215 D418
mtm@...| FreeBSD - Unleash the Daemon !

#610 From: Luke Mewburn <lukem@...>
Date: Tue Jan 6, 2004 1:35 am
Subject: Re: Re: cvs commit: src/etc/rc.d motd
lukem@...
Send Email Send Email
 
On Mon, Dec 01, 2003 at 02:30:37PM +0300, Mike Makonnen wrote:
   | Does this mean we should remove the rest of the compatibility stuff
   | in other scripts? As you say, the NetBSD folks don't seem interested
   | in our changes. We originally had that compatibility stuff because
   | we expected to iron them out with NetBSD, but it's been a full year
   | since we did this and several attempts to get the NetBSD folks interested
   | have failed. Plus, it just makes the affected scripts more cluttered
   | and confusing.

FWIW; whilst NetBSD is unlikely to share the same /etc/rc.d/* scripts
with FreeBSD (10 years of feature skew between our projects),
maintaining compatibility in rc.subr(8) and in the "end user experience"
is useful.


Cheers,
Luke.

#609 From: "Doug" <DougB@...>
Date: Tue Jan 6, 2004 1:10 am
Subject: Update to mergemaster
domain_name_...
Offline Offline
Send Email Send Email
 
Guys,

FYI, I updated mergemaster last week to detect any files in /etc/rc.d
(or ${DESTDIR}/etc/rc.d if they are different) that aren't in
${TEMPROOT}/etc/rc.d, and offer to delete them for the user if
detected. This should go a long way towards solving a lot of the
problems users have had with stale files in /etc/rc.d clogging up the
works.

Doug

#584 From: Doug Barton <DougB@...>
Date: Mon Dec 29, 2003 9:06 pm
Subject: Re: cvs commit: src/etc/rc.d syscons
domain_name_...
Offline Offline
Send Email Send Email
 
Peter Wemm wrote:
> peter       2003/12/10 07:48:50 PST
>
>   FreeBSD src repository
>
>   Modified files:
>     etc/rc.d             syscons
>   Log:
>   Change rc.d/syscons to not need /usr/sbin/ispcvt to exist.  This should
>   make it work for all non-i386 syscons platforms.
>
>   Revision  Changes    Path
>   1.10      +7 -5      src/etc/rc.d/syscons

This is a good change, thanks Peter.

Doug

#490 From: Mike Makonnen <mtm@...>
Date: Mon Dec 1, 2003 11:30 am
Subject: Re: cvs commit: src/etc/rc.d motd
mike_makonnen
Offline Offline
Send Email Send Email
 
On Mon, Oct 13, 2003 at 01:44:07AM -0700, Doug Barton wrote:
> dougb       2003/10/13 01:44:07 PDT
>
>   FreeBSD src repository
>
>   Modified files:
>     etc/rc.d             motd
>   Log:
>   * Remove the OS specific bits, since NetBSD isn't interested in
>   porting this stuff back.

Does this mean we should remove the rest of the compatibility stuff
in other scripts? As you say, the NetBSD folks don't seem interested
in our changes. We originally had that compatibility stuff because
we expected to iron them out with NetBSD, but it's been a full year
since we did this and several attempts to get the NetBSD folks interested
have failed. Plus, it just makes the affected scripts more cluttered
and confusing. So, I think we should just bite the bullet and announce
on -arch that we're going to do it sometime before 5.3.
What do you think?

Cheers.
--
Mike Makonnen  | GPG-KEY: http://www.identd.net/~mtm/mtm.asc
mtm@... | Fingerprint: 00E8 61BC 0D75 7FFB E4D3  6BF1 B239 D010 3215 D418
mtm@...| FreeBSD - Unleash the Daemon !

#433 From: Tobias Roth <yahoo@...>
Date: Sat Nov 8, 2003 4:47 pm
Subject: PLEASE TEST: (laptop) autoconf at boot
roth_tob
Offline Offline
Send Email Send Email
 
Hi

I'd like to present some patches to teach FreeBSD to automatically
configure itself depending on what network it is started in.

The system depends on rcng, so 5.x is a requirement. The setup of
the various network profiles is done manually, after that, whenever
the laptop boots or wakes up from suspend, it detects where it is
located and configures itself accodringly.

Please send all comments to freebsd-current so the discussion is not
scattered over several mailing lists.


How to patch:

cd /
fetch http://depot.fsck.ch/profile.diff
patch < profile.diff
rm /etc/rc.d/profile.orig /usr/share/man/man8/profile.8.orig
chmod 555 /etc/rc.d/profile
man profile


Features:
  - unattended startup, the laptop discovers automatically in what
    network it is started
  - read-only root partitions are supported
  - unintrusive. getting rid of everything profile-related is just a
    matter of turning it off in rc.conf and rm'ing the profile dir
  - everything under /etc is customizable per environment, not just the
    network


Drawbacks:
  - setup is a bit tedious
  - autodetection after suspend/resume does not work completely yet
  - during normal operation, changes to /etc are not straight forward
    anymore. see the manpage for details.


Notes:
  - I already have an idea about how to fix suspend/resume support. But
    as this involves some more changes to the system I'd like to hear a
    few opinions on the profile idea as a whole before starting with that.
  - The arguments for mdmfs/newfs are somewhat arbitrary. I just chose
    what seemed to work, someone with more insight might come up with
    a better sort of switches.

#423 From: Brooks Davis <brooks@...>
Date: Wed Nov 5, 2003 1:49 am
Subject: rc.d/diskless newaliases patch
brdavis
Offline Offline
Send Email Send Email
 
Any objections to this rc.d/diskless patch to avoid running newaliases
on machines which aren't using sentmail/mailwrapper?  I deliberatly
duplicated the case statement because this part is not related to
configuring /var.

-- Brooks

Index: diskless
===================================================================
RCS file: /usr/cvs/src/etc/rc.d/diskless,v
retrieving revision 1.29
diff -u -p -r1.29 diskless
--- diskless 13 Oct 2003 08:18:05 -0000 1.29
+++ diskless 4 Nov 2003 23:42:38 -0000
@@ -107,7 +107,13 @@ echo "+++ create lastlog"
  # Make sure our aliases database is uptodate, the aliases may have
  # been overriden in /conf.
  #
-/usr/bin/newaliases
+case ${sendmail_enable} in
+[Nn][Oo][Nn][Ee])
+ ;;
+*)
+ /usr/bin/newaliases
+ ;;
+esac

  # XXX make sure to create one dir for each printer as requested by lpd
  #

--
Any statement of the form "X is the one, true Y" is FALSE.
PGP fingerprint 655D 519C 26A7 82E7 2529  9BF0 5D8E 8BE9 F238 1AD4

#420 From: Brooks Davis <brooks@...>
Date: Tue Nov 4, 2003 6:42 pm
Subject: Re: updated rc.diskless
brdavis
Offline Offline
Send Email Send Email
 
On Tue, Nov 04, 2003 at 10:24:27AM -0800, Gordon Tetlow wrote:
> On Tue, Nov 04, 2003 at 10:19:45AM -0800, Brooks Davis wrote:
> > On Mon, Nov 03, 2003 at 11:37:13PM -0800, Matt Peterson wrote:
> > > Howdy,
> > >
> > > I've made some updates to rc.d/rc.diskless for use in read-only flash
> > > systems (typically Soekris, etc embedded boards).  phk said I should
> > > track down DougB, who appears to have his plate full, so hopfully
> > > someone else can step in.. ;)
> >
> > I can work on this.  I've got an intrest in diskless setups my self.
> > Some comments:
> >
> > Replacing tabs with spaces makes the diffs hard to follow.
> >
> > I like the idea of extending diskless to read-only systems.  I can't
> > access the alternate patch you mention in your PR so I'm not sure how
> > that works.  Autodetection looks like a somewhat tricky issue, but I'm
> > sure there's a solution if that's desired.
> >
> > Moving newaliases makes sense.
>
> I'm worried about all the calls to grep. Since grep lives in /usr/bin
> this makes things kinda sticky (not to mention a call to sed).

I'd definatly plan to remove all /usr stuff before the "mount -a" and
limit it after.  I'm pretty sure autodetection can be done with shell
matching and possiably expr.

-- Brooks

--
Any statement of the form "X is the one, true Y" is FALSE.
PGP fingerprint 655D 519C 26A7 82E7 2529  9BF0 5D8E 8BE9 F238 1AD4

#419 From: Gordon Tetlow <gordont@...>
Date: Tue Nov 4, 2003 6:24 pm
Subject: Re: updated rc.diskless
tetlowgm
Offline Offline
Send Email Send Email
 
On Tue, Nov 04, 2003 at 10:19:45AM -0800, Brooks Davis wrote:
> On Mon, Nov 03, 2003 at 11:37:13PM -0800, Matt Peterson wrote:
> > Howdy,
> >
> > I've made some updates to rc.d/rc.diskless for use in read-only flash
> > systems (typically Soekris, etc embedded boards).  phk said I should
> > track down DougB, who appears to have his plate full, so hopfully
> > someone else can step in.. ;)
>
> I can work on this.  I've got an intrest in diskless setups my self.
> Some comments:
>
> Replacing tabs with spaces makes the diffs hard to follow.
>
> I like the idea of extending diskless to read-only systems.  I can't
> access the alternate patch you mention in your PR so I'm not sure how
> that works.  Autodetection looks like a somewhat tricky issue, but I'm
> sure there's a solution if that's desired.
>
> Moving newaliases makes sense.

I'm worried about all the calls to grep. Since grep lives in /usr/bin
this makes things kinda sticky (not to mention a call to sed).

-gordon

#418 From: Brooks Davis <brooks@...>
Date: Tue Nov 4, 2003 6:19 pm
Subject: Re: updated rc.diskless
brdavis
Offline Offline
Send Email Send Email
 
On Mon, Nov 03, 2003 at 11:37:13PM -0800, Matt Peterson wrote:
> Howdy,
>
> I've made some updates to rc.d/rc.diskless for use in read-only flash
> systems (typically Soekris, etc embedded boards).  phk said I should
> track down DougB, who appears to have his plate full, so hopfully
> someone else can step in.. ;)

I can work on this.  I've got an intrest in diskless setups my self.
Some comments:

Replacing tabs with spaces makes the diffs hard to follow.

I like the idea of extending diskless to read-only systems.  I can't
access the alternate patch you mention in your PR so I'm not sure how
that works.  Autodetection looks like a somewhat tricky issue, but I'm
sure there's a solution if that's desired.

Moving newaliases makes sense.

-- Brooks

--
Any statement of the form "X is the one, true Y" is FALSE.
PGP fingerprint 655D 519C 26A7 82E7 2529  9BF0 5D8E 8BE9 F238 1AD4

#416 From: Matt Peterson <matt@...>
Date: Tue Nov 4, 2003 7:37 am
Subject: updated rc.diskless
matt@...
Send Email Send Email
 
Howdy,

I've made some updates to rc.d/rc.diskless for use in read-only flash
systems (typically Soekris, etc embedded boards).  phk said I should
track down DougB, who appears to have his plate full, so hopfully
someone else can step in.. ;)

http://www.freebsd.org/cgi/query-pr.cgi?pr=misc/58272

--Matt

#413 From: Doug Barton <DougB@...>
Date: Thu Oct 30, 2003 9:27 am
Subject: Re: conf/58680: [PATCH] RCNG: shouldn't ldconfig be started before SERVERS? (fwd)
DougB@...
Send Email Send Email
 
FYI. I'm a little out of touch atm, so if someone wants to grab this,
feel free.

Doug


---------- Forwarded message ----------
From: Kris Kennaway <kris@...>
To: kris@..., freebsd-bugs@..., dougb@...
Date: Thu, 30 Oct 2003 01:15:18 -0800 (PST)
Subject: Re: conf/58680: [PATCH] RCNG: shouldn't ldconfig be started before
     SERVERS?

Synopsis: [PATCH] RCNG: shouldn't ldconfig be started before SERVERS?

Responsible-Changed-From-To: freebsd-bugs->dougb
Responsible-Changed-By: kris
Responsible-Changed-When: Thu Oct 30 01:15:01 PST 2003
Responsible-Changed-Why:
Assign to rc.d developer

http://www.freebsd.org/cgi/query-pr.cgi?pr=58680

#386 From: Doug Barton <DougB@...>
Date: Mon Oct 13, 2003 8:48 am
Subject: Improving cleanvar, re diskless boot
DougB@...
Send Email Send Email
 
Guys,

Please see very interesting suggestions below from phk regarding ways to
improve cleanvar, especially in the presence of a diskless boot. I like
these ideas, but wanted to run them by y'all first.

Doug

---------- Forwarded message ----------
From: Poul-Henning Kamp <phk@...>
To: Doug Barton <DougB@...>
Date: Fri, 10 Oct 2003 16:38:11 +0200
Subject: Re: "send patches" :-)


By all means forward to whoever you think appropriate.

Basically what I want to be able to do is run my embedded
systems with an /etc/fstab which looks like:

	 ad0s1a  /       ufs ro  1 1
	 md /tmp mfs rw,-s1m 2 0
	 md /var mfs rw,-s8m 2 0

Poul-Henning


>On Thu, 9 Oct 2003, Poul-Henning Kamp wrote:
>
>>
>> The first patch does the /var initialization like I talked about.
>> it should be possible to remove the equivalent code in diskless.
>>
>> Index: cleanvar
>> ===================================================================
>> RCS file: /home/ncvs/src/etc/rc.d/cleanvar,v
>> retrieving revision 1.5
>> diff -u -r1.5 cleanvar
>> --- cleanvar 14 Jul 2003 13:02:36 -0000 1.5
>> +++ cleanvar 9 Oct 2003 13:21:56 -0000
>> @@ -7,6 +7,12 @@
>>  # REQUIRE: mountcritlocal
>>  # KEYWORD: FreeBSD
>>
>> +. /etc/rc.subr
>> +
>> +name="cleanvar"
>> +
>> +load_rc_config $name
>> +
>>  purgedir()
>>  {
>>   local dir file
>> @@ -31,6 +37,46 @@
>>  	 done
>>   fi
>>  }
>> +
>> +# Provide a function for normalizing the mounting of memory
>> +# filesystems.  This should allow the rest of the code here to remain
>> +# as close as possible between 5-current and 4-stable.
>> +#   $1 = size
>> +#   $2 = mount point
>> +#   $3 = (optional) bytes-per-inode
>> +mount_md() {
>> + if [ -n "$3" ]; then
>> +  bpi="-i $3"
>> + fi
>> + /sbin/mdmfs $bpi -s $1 -M md $2
>> +}
>> +
>> +# If we do not have a writable /var, create a memory
>> +# filesystem for /var.  We don't have /usr yet so
>> +# use mkdir instead of touch to test.  We want mount
>> +# to record its mounts so we have to make sure /var/db
>> +# exists before doing the mount -a.
>> +#
>> +
>> +if (/bin/mkdir /var/.diskless 2> /dev/null); then
>> +        rmdir /var/.diskless
>> +else
>> + mkdir -p /var
>> + mount_md ${varsize:=32m} /var
>> +fi
>> +
>> +# Populate /var if it looks empty
>> +if [ -d /var/run -a -d /var/db -a -d /var/empty ] ; then
>> + true
>> +else
>> + /usr/sbin/mtree -deU -f /etc/mtree/BSD.var.dist -p /var > /dev/null 2>&1
>> + LOGFILES=`/usr/bin/awk '$1 != "#" { printf "%s ", $1 } '
/etc/newsyslog.conf`
>> + if [ -n "$LOGFILES" ]; then
>> +  /usr/bin/touch $LOGFILES
>> + fi
>> + /usr/bin/touch /var/log/lastlog
>> +
>> +fi
>>
>>  # These files must be removed only the first time this script is run
>>  # on boot.

--
Poul-Henning Kamp       | UNIX since Zilog Zeus 3.20
phk@...         | TCP/IP since RFC 956
FreeBSD committer       | BSD since 4.3-tahoe
Never attribute to malice what can adequately be explained by incompetence.

#369 From: Doug Barton <DougB@...>
Date: Thu Sep 18, 2003 10:05 am
Subject: Re: Problem with /etc/rc.d/gbde
DougB@...
Send Email Send Email
 
On Wed, 17 Sep 2003, Garrett Wollman wrote:

> <<On Wed, 17 Sep 2003 00:25:08 -0700 (PDT), Doug Barton <DougB@...>
said:
>
> > So at this point, I'd like to either fix rc.conf, or unhook it. What do
> > you guys think?
>
> That's a bug that was never fixed because I didn't test that case. :-(
> It should default to no.

Thanks. I committed the rc.conf default and rc.conf.5 update.

Doug

--

     This .signature sanitized for your protection

#367 From: Garrett Wollman <wollman@...>
Date: Wed Sep 17, 2003 4:27 pm
Subject: Problem with /etc/rc.d/gbde
wollman@...
Send Email Send Email
 
<<On Wed, 17 Sep 2003 00:25:08 -0700 (PDT), Doug Barton <DougB@...>
said:

> So at this point, I'd like to either fix rc.conf, or unhook it. What do
> you guys think?

That's a bug that was never fixed because I didn't test that case. :-(
It should default to no.

-GAWollman

#366 From: Doug Barton <DougB@...>
Date: Wed Sep 17, 2003 7:25 am
Subject: Problem with /etc/rc.d/gbde
DougB@...
Send Email Send Email
 
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Guys,

There is no $gbde_autoattach_all variable in /etc/defaults/rc.conf, and
it's generating an error at boot time. When Garrett initially committed
this script, he didn't hook it to the build on purpose, but it was
subsequently hooked up by Mike.

So at this point, I'd like to either fix rc.conf, or unhook it. What do
you guys think?

Doug

- --

     This .signature sanitized for your protection

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.3 (FreeBSD)

iD8DBQE/aAxWyIakK9Wy8PsRAmEOAJ9gRPm+1VnM3+DAHPmz2VTvciuKPgCdEWE0
lyIqyuYl27rtRqnUU6EQ7zM=
=AWDB
-----END PGP SIGNATURE-----

#364 From: Martin Blapp <mb@...>
Date: Mon Sep 15, 2003 6:24 pm
Subject: Any objections against this patch ?
mb@...
Send Email Send Email
 
===================================================================
Do not kill dhclient twice. If we execute dhclient -r,
dhclient gets already killed, so there is no need to
do it twice. But only do it, if we release some leases.
===================================================================
RCS file: /home/ncvs/src/etc/rc.d/dhclient,v
retrieving revision 1.9
diff -u -r1.9 dhclient
--- dhclient 28 Jul 2003 08:15:52 -0000 1.9
+++ dhclient 15 Sep 2003 16:36:13 -0000
@@ -53,8 +53,6 @@

  dhclient_prestart()
  {
- dhclient_common || return 1
-
 	 for ifn in ${_cooked_list}; do
 		 ifscript_up ${ifn}
 	 done
@@ -78,8 +76,6 @@

  dhclient_prestop()
  {
- dhclient_common || return 1
-
 	 for ifn in ${_cooked_list}; do
 		 ipx_down ${ifn}
 		 ifalias_down ${ifn}
@@ -110,4 +106,10 @@
  fi

  load_rc_config $name
+dhclient_common
+if [ -n "$_cooked_list" ]; then
+ if [ -s $pidfile ]; then
+  stop_cmd=":"
+ fi
+fi
  run_rc_command "$1"

Martin Blapp, <mb@...> <mbr@...>
------------------------------------------------------------------
ImproWare AG, UNIXSP & ISP, Zurlindenstrasse 29, 4133 Pratteln, CH
Phone: +41 61 826 93 00 Fax: +41 61 826 93 01
PGP: <finger -l mbr@...>
PGP Fingerprint: B434 53FC C87C FE7B 0A18 B84C 8686 EF22 D300 551E
------------------------------------------------------------------

#361 From: Lukas Ertl <l.ertl@...>
Date: Wed Sep 10, 2003 11:23 am
Subject: Re: rcorder hack and oddity
l.ertl@...
Send Email Send Email
 
On Sun, 7 Sep 2003, Doug Barton wrote:

> I would like to see us add this feature to rcorder, but I think we need
> some volunteers to test boot it on a variety of different systems before
> we turn it loose on the world. :)  I'm also interested Luke's opinions
> on the topic as well.

FWIW, I've submitted a PR with the patch, in case anyone wants to look at
it: <http://www.freebsd.org/cgi/query-pr.cgi?pr=56648>.

regards,
le

--
Lukas Ertl                             eMail: l.ertl@...
UNIX Systemadministrator               Tel.:  (+43 1) 4277-14073
Vienna University Computer Center      Fax.:  (+43 1) 4277-9140
University of Vienna                   http://mailbox.univie.ac.at/~le/

#358 From: Tim Kientzle <kientzle@...>
Date: Mon Sep 8, 2003 7:21 am
Subject: Re: [naddy@...: -CURRENT rc_ng: named_rcng]
timkientzle
Offline Offline
Send Email Send Email
 
Hmmm...  I only have a couple of free minutes here, but I
skimmed through this.

I think that named_rcng is simply mis-named.  It's used twice
in /etc/rc.d/named.  The second looks bogus; I'm pretty sure
it (and the entire case statement around it) can safely
be deleted.

Regardless of how named_rcng is set, /etc/rc.d/named will
still start named.  (This is why I say it's mis-named;
Christian seems to have misunderstood it to determine whether
or not /etc/rc.d/named would start named.)  The difference
is simply which set of variables get used:

named_rcng = NO
      named_flags  is obeyed
      named_chrootdir, named_chroot_autoupdate, and named_symlink_enable
are not obeyed.

named_rcng = YES
      named_flags is not obeyed; it gets overwritten with auto-generated
flags
      named_chrootdir, named_chroot_autoupdate, and named_symlink_enable
are obeyed.

Forcing it YES certainly has the potential of breaking some
existing installations because it ignores named_flags.
If we're going to do it, do it before 5.2.  However, I would
suggest changing the code so that named_flags gets obeyed if
it is set.  In that case, we could dump named_rcng, set
named_flags="" in /etc/defaults/rc.conf and just possibly
manage to avoid breaking anything.

Like I said, this is all based on a pretty cursory study;
I might be mis-reading something.

In any case, the comments in /etc/defaults/rc.conf should be
augmented to make it clear which variables are obeyed for
each setting of named_rcng.

Tim

Gordon Tetlow wrote:
> Forwarded to the rc mailing list. Tim, do you want to weigh in on this?
>
> IIRC, it has something to do with the way NetBSD does named startup
> (which is in a chroot?) while we do it the old fashioned simpler way.
>
> -gordon
>
> ----- Forwarded message from Christian Weisgerber <naddy@...> -----
>
> Date: Sun, 7 Sep 2003 13:28:42 +0200
> From: Christian Weisgerber <naddy@...>
> To: gordon@...
> Subject: -CURRENT rc_ng: named_rcng
> X-Spam-Status: No, hits=-7.5 required=6.5
>  tests=BAYES_10,USER_AGENT_MUTT
>  autolearn=ham version=2.55
>
> Shouldn't named_rcng default to "YES" now or in fact be completely
> removed, considering that no alternative startup exists any longer?
>

Messages 358 - 729 of 729   Newest  |  < Newer  |  Older >  |  Oldest
Advanced
Add to My Yahoo!      XML What's This?

Copyright © 2009 Yahoo! Inc. All rights reserved.
Privacy Policy - Terms of Service - Guidelines - Help