Re: linking a dir

2003-09-16 Thread Andrew L. Gould
On Tuesday 16 September 2003 10:51 am, Gary wrote:
 Hello Guys,

 It seems that on a remote box FBSD 4.8, my /dev/ad0s1a or / dir is at 73%
 capacity already, and this has me somewhat worried.  I attribute this to
 the /etc dir inside of the / dir, as it contains many log files, etc... or
 perhaps the 2 kernels sitting under /  both kernel and kernel.GENERIC

 Question is can I cp /etc to say a /usr/etc and link it (as I have tons of
 room under /usr) without any problem.

 Thanks for input..

I don't think you should do this.  In single-user mode, I don't think /usr 
would be mounted; so the system wouln't have access to /usr/etc until you 
mounted /usr manually.

Andrew Gould
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: linking a dir

2003-09-16 Thread Mike Maltese
Deleteing unused kernels would be a good start.  What is the size of your /
partition?  Add most puzzling of all, why do you have logs in /etc?  There
should be very little write activity on /, so the possiblilty of it filling
up shouldn't be much of a concern.

- Original Message - 
From: Gary [EMAIL PROTECTED]
To: freebsd-questions [EMAIL PROTECTED]
Sent: Tuesday, September 16, 2003 8:51 AM
Subject: linking a dir


 Hello Guys,

 It seems that on a remote box FBSD 4.8, my /dev/ad0s1a or / dir is at 73%
capacity
 already, and this has me somewhat worried.  I attribute this to the /etc
 dir inside of the / dir, as it contains many log files, etc... or perhaps
 the 2 kernels sitting under /  both kernel and kernel.GENERIC

 Question is can I cp /etc to say a /usr/etc and link it (as I have tons of
 room under /usr) without any problem.

 Thanks for input..

 -- 
 Best regards,
  Gary

 ___
 [EMAIL PROTECTED] mailing list
 http://lists.freebsd.org/mailman/listinfo/freebsd-questions
 To unsubscribe, send any mail to
[EMAIL PROTECTED]

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: linking a dir

2003-09-16 Thread Viktor Lazlo


On Tue, 16 Sep 2003, Gary wrote:

 Hello Guys,

 It seems that on a remote box FBSD 4.8, my /dev/ad0s1a or / dir is at 73% capacity
 already, and this has me somewhat worried.  I attribute this to the /etc
 dir inside of the / dir, as it contains many log files, etc... or perhaps
 the 2 kernels sitting under /  both kernel and kernel.GENERIC

 Question is can I cp /etc to say a /usr/etc and link it (as I have tons of
 room under /usr) without any problem.

The more usual culprit is /root if you have been using the superuser
account to access things better suited to a normal user.  Logfiles
normally go to /var rather than /etc, which mostly contains configuration
files and startup scripts.  du is your friend in this situation.

Cheers,

Viktor
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: linking a dir

2003-09-16 Thread Gary
Hello Mike,

Tuesday, September 16, 2003, 11:04:55 AM, you wrote:

MM Deleteing unused kernels would be a good start.  What is the size of your /
MM partition?

dev/ad0s1a128990   86254   3241873%/

-r-xr-xr-x   1 root  wheel  4122347 Apr  3 04:53 kernel
-r-xr-xr-x   1 root  wheel  4122347 Apr  3 04:53 kernel.GENERIC

I don't know which kernel is being used... Deleting one would surely help.

MM Add most puzzling of all, why do you have logs in /etc? There should
MM be very little write activity on /, so the possiblilty of it filling
MM up shouldn't be much of a concern.

Good question. This is a production Mail / DNS server (using qmail and
djbdns), so I have logs in /etc (by the default run script) minimally at
100K each x10 (before they rotate out) for each of SMTP, SEND, another
SMTP, axfrdns, tinydns, dnscache, 2 rbls, and maybe one more... the SMTP
and SEND logs are at 250k each of 10... so you see how this can add up...

I am hoping that I will have seen just about the end of the bloating /
dir, but was concerned enough to write about it...  I should have planned
the layout better.

 It seems that on a remote box FBSD 4.8, my /dev/ad0s1a or / dir is at 73%
 capacity
 already, and this has me somewhat worried.  I attribute this to the /etc
 dir inside of the / dir, as it contains many log files, etc... or perhaps
 the 2 kernels sitting under /  both kernel and kernel.GENERIC

 Question is can I cp /etc to say a /usr/etc and link it (as I have tons of
 room under /usr) without any problem.

 Thanks for input..

-- 
Best regards,
 Gary 

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: linking a dir

2003-09-16 Thread Gary
Hello Andrew,

Tuesday, September 16, 2003, 10:59:19 AM, you wrote:

 room under /usr) without any problem.

 Thanks for input..

ALG I don't think you should do this.  In single-user mode, I don't think /usr
ALG would be mounted; so the system wouln't have access to /usr/etc until you
ALG mounted /usr manually.

Excellent point.. given this limitation and caution, do you think it is
still doable?

-- 
Best regards,
 Gary 

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: linking a dir

2003-09-16 Thread Mike Maltese
 dev/ad0s1a128990   86254   3241873%/

 -r-xr-xr-x   1 root  wheel  4122347 Apr  3 04:53 kernel
 -r-xr-xr-x   1 root  wheel  4122347 Apr  3 04:53 kernel.GENERIC

 I don't know which kernel is being used... Deleting one would surely help.

Unless you're specifying it at boot, you can safely remove kernel.GENERIC.


 Good question. This is a production Mail / DNS server (using qmail and
 djbdns), so I have logs in /etc (by the default run script) minimally at
 100K each x10 (before they rotate out) for each of SMTP, SEND, another
 SMTP, axfrdns, tinydns, dnscache, 2 rbls, and maybe one more... the SMTP
 and SEND logs are at 250k each of 10... so you see how this can add up...

I run postfix and BIND, so I'm not particularly familiar with those
packages. I would think that there's some facility in those programs to
specify a more appropriate place (like /var/log). Alternatively, if your
logs are rotated by newsyslog, you could keep fewer log files and/or use
bzip2 compression on the old ones. If not, you could write a shell script to
accomplish the same thing. bzip2 gets my 500K maillogs down to ~35K, and I
also keep 10 of them, so the savings is significant.

The problem I have with this is 250K*10 and 100K*10 only adds up to 3.5M,
hardly enough to take up the remainder of your partition. Do you have
anything hanging around in /root?

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: linking a dir

2003-09-16 Thread Andrew L. Gould
On Tuesday 16 September 2003 11:31 am, Gary wrote:
 Hello Andrew,

 Tuesday, September 16, 2003, 10:59:19 AM, you wrote:
  room under /usr) without any problem.
 
  Thanks for input..

 ALG I don't think you should do this.  In single-user mode, I don't think
 /usr ALG would be mounted; so the system wouln't have access to /usr/etc
 until you ALG mounted /usr manually.

 Excellent point.. given this limitation and caution, do you think it is
 still doable?

I'm not an expert; but it just doesn't pass the sniff test.  I wouldn't do it.

Andrew
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: linking a dir

2003-09-16 Thread Mike Maltese
 How do I know which one is being loaded, can't seem to find it in dmesg.

I think it's safe to assume that you're not booting kernel.GENERIC.  You can
specify other kernels at boot time, but if you're not doing that, you can
safely delete kernel.GENERIC.  Some like having a generic kernel around in
case of an emergency, a newly built kernel doesn't work correctly or for
troubleshooting purposes.  Have you built a new kernel or upgraded the
entire system?  What's the output of uname -v?

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: linking a dir

2003-09-16 Thread Gary
Hello Mike,

Tuesday, September 16, 2003, 1:14:38 PM, you wrote:

 How do I know which one is being loaded, can't seem to find it in dmesg.

MM I think it's safe to assume that you're not booting kernel.GENERIC.  You can
MM specify other kernels at boot time, but if you're not doing that, you can
MM safely delete kernel.GENERIC.

Okay..

MM Some like having a generic kernel around in case of an emergency, a
MM newly built kernel doesn't work correctly or for troubleshooting
MM purposes.

good idea..

MM Have you built a new kernel or upgraded the entire system? What's the
MM output of uname -v?

no, haven't touched it, as it worked well out of the box.  Use it
strictly for mail/IMAPS/DNS server.

FreeBSD 4.8-RELEASE #0: Thu Apr 3 10:53:38 GMT 2003
[EMAIL PROTECTED]:/usr/obj/usr/src/sys/GENERIC


-- 
Best regards,
 Gary 

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: linking a dir

2003-09-16 Thread Mike Maltese
 FreeBSD 4.8-RELEASE #0: Thu Apr 3 10:53:38 GMT 2003
 [EMAIL PROTECTED]:/usr/obj/usr/src/sys/GENERIC

If you ls -l / | grep kernel, you'll notice that kernel and kernel.GENERIC
are identical in size. If you were to ever build a new kernel, your current
would be moved to kernel.old, so it's rather redundant to keep
kernel.GENERIC around.  I guess this is pretty trivial now that you've
tracked down the source of disk usage, but hey, 4MB is 4MB. =)

Mike

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: linking a dir

2003-09-16 Thread Gary
Hello Mike,

Tuesday, September 16, 2003, 1:59:11 PM, you wrote:

 FreeBSD 4.8-RELEASE #0: Thu Apr 3 10:53:38 GMT 2003
 [EMAIL PROTECTED]:/usr/obj/usr/src/sys/GENERIC

MM If you ls -l / | grep kernel, you'll notice that kernel and kernel.GENERIC
MM are identical in size.

Yes, I see that on the grep... good info.

MM If you were to ever build a new kernel, your current would be moved to
MM kernel.old, so it's rather redundant to keep kernel.GENERIC around. I
MM guess this is pretty trivial now that you've tracked down the source
MM of disk usage, but hey, 4MB is 4MB. =)

LOL, you got that right... thanks for your help and ideas.. as well as to
everyone who pitched in... appreciate it.


-- 
Best regards,
 Gary 

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: linking a dir

2003-09-16 Thread Viktor Lazlo


On Tue, 16 Sep 2003, Gary wrote:

 Hello Mike,

 Tuesday, September 16, 2003, 11:58:31 AM, you wrote:

  dev/ad0s1a128990   86254   3241873%/
 
  -r-xr-xr-x   1 root  wheel  4122347 Apr  3 04:53 kernel
  -r-xr-xr-x   1 root  wheel  4122347 Apr  3 04:53 kernel.GENERIC
 
  I don't know which kernel is being used... Deleting one would surely help.

 MM Unless you're specifying it at boot, you can safely remove kernel.GENERIC.

 How do I know which one is being loaded, can't seem to find it in dmesg.

Whichever kernel is specified as kernel will be loaded by default unless
you specify otherwise at the boot prompt.  If you have built multiple
kernels and need to verify which is the current default, uname -a will
identify which source was used. I think kernel.GENERIC is included by
default with each release to make sure you have a bootable kernel in the
event of problems with one you have compiled yourself and can be moved or
deleted if you are using the default anyways.

Cheers,

Viktor
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: linking a dir

2003-09-16 Thread Gary
Hi Viktor,

--On Tuesday, September 16, 2003 07:16:30 PM -0700 Viktor Lazlo 
[EMAIL PROTECTED] wrote:

I think kernel.GENERIC is included by
default with each release to make sure you have a bootable kernel in the
event of problems with one you have compiled yourself and can be moved or
deleted if you are using the default anyways.
Many thanks for your input Viktor.. I appreciate it.. Between this 
kernel.GENERIC and the SMTPD in /opt this will do it quite nicely..

--
Gary
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]