Geli and crunchgen (/rescue)

2013-08-03 Thread Dewayne
Unfortunately I have had the need on several occasions to recover systems that 
use geli encrypted disks.  Unfortunately geli is not
included in the crunchgen /rescue directory.  Has anyone been successful in 
crunchgen'ing geli into /rescue?

I've spent a few hours on this and think herding cats might be easier.

Regards, Dewayne.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


.sh script code to determine IPv4 or IPv6

2013-08-03 Thread Fbsd8

I have a .sh script that I need to determine if the entered IP address
is IPv4 or IPv6.

Is there some .sh command that does this?

Thanks

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


.sh script code to determine IPv4 or IPv6

2013-08-03 Thread Robert Huff

Fbsd8 writes:

  I have a .sh script that I need to determine if the entered IP
  address is IPv4 or IPv6.
  
  Is there some .sh command that does this?

Not that I know of.
But ... how hard can it be to figure out whether it uses '.' or
':'?


Robert Huff

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Geli and crunchgen (/rescue)

2013-08-03 Thread Teske, Devin

On Aug 3, 2013, at 12:35 AM, Dewayne wrote:

 Unfortunately I have had the need on several occasions to recover systems 
 that use geli encrypted disks.  Unfortunately geli is not
 included in the crunchgen /rescue directory.  Has anyone been successful in 
 crunchgen'ing geli into /rescue?
 
 I've spent a few hours on this and think herding cats might be easier.
 

I'll give it a go. I've got a fair amount of experience with crunchgen...

Oh, wait... I already did it... (see below link):

http://druidbsd.cvs.sf.net/viewvc/druidbsd/druidbsd/druid/dep/freebsd/patches/local_patches/release%3A%3Ai386%3A%3Aboot_crunch.conf.patch?revision=1.2view=markup

There you go ;D (smiles)
-- 
Devin

_
The information contained in this message is proprietary and/or confidential. 
If you are not the intended recipient, please: (i) delete the message and all 
copies; (ii) do not disclose, distribute or use the message in any manner; and 
(iii) notify the sender immediately. In addition, please be aware that any 
message addressed to our domain is subject to archiving and review by persons 
other than the intended recipient. Thank you.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: .sh script code to determine IPv4 or IPv6

2013-08-03 Thread Teske, Devin

On Aug 3, 2013, at 4:30 AM, Fbsd8 wrote:

 I have a .sh script that I need to determine if the entered IP address
 is IPv4 or IPv6.
 
 Is there some .sh command that does this?
 

In RELENG_9, soon to be released 9.2-R:

=== FILE: wis ===
#!/bin/sh
DEVICE_SELF_SCAN_ALL=
. /usr/share/bsdconfig/media/tcpip.subr
if f_validate_ipaddr6 $1; then
echo Hey, nice IPv6 addr, great job!
elif f_validate_ipaddr $1; then
echo Hey, nice IPv4 addr; smiles
elif f_validate_hostname $1; then
echo Hey, nice hostname
else
echo What on Earth wast, _that_?!
exit 1
fi
=== END FILE ===

dte...@scribe9.vicor.com ~ $ ./wis ::1
Hey, nice IPv6 addr, great job!
dte...@scribe9.vicor.com ~ $ ./wis 0::1
Hey, nice IPv6 addr, great job!
dte...@scribe9.vicor.com ~ $ ./wis 0:::1
What on Earth wast, _that_?!
dte...@scribe9.vicor.com ~ $ ./wis 1.2.3.4
Hey, nice IPv4 addr; smiles
dte...@scribe9.vicor.com ~ $ ./wis 0.2.3.4
Hey, nice IPv4 addr; smiles
dte...@scribe9.vicor.com ~ $ ./wis 256.2.3.4
Hey, nice hostname
dte...@scribe9.vicor.com ~ $ ./wis foo.bar.com
Hey, nice hostname
dte...@scribe9.vicor.com ~ $ ./wis abc-123
Hey, nice hostname
dte...@scribe9.vicor.com ~ $ ./wis abc_123
What on Earth wast, _that_?!


-- 
Cheers,
Devin

_
The information contained in this message is proprietary and/or confidential. 
If you are not the intended recipient, please: (i) delete the message and all 
copies; (ii) do not disclose, distribute or use the message in any manner; and 
(iii) notify the sender immediately. In addition, please be aware that any 
message addressed to our domain is subject to archiving and review by persons 
other than the intended recipient. Thank you.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: .sh script code to determine IPv4 or IPv6

2013-08-03 Thread Teske, Devin

On Aug 3, 2013, at 5:04 AM, Robert Huff wrote:

 
 Fbsd8 writes:
 
 I have a .sh script that I need to determine if the entered IP
 address is IPv4 or IPv6.
 
 Is there some .sh command that does this?
 
   Not that I know of.
   But ... how hard can it be to figure out whether it uses '.' or
 ':'?
 

Actually, there's /usr/share/bsdconfig/media/tcpip.subr

Function family:

f_validate_ipaddr6 $ipv6_addr
# Should be complete; I digested multiple RFCs on IPv6

f_validate_ipaddr $ipv4_addr [$netmask]
# optional netmask to validate IP is within doubly-valid

f_validate_hostname $hostname
# To RFC specifications 952 and 1123

But if you need to prompt the user to enter a value and then validate it, the 
above functions return meaningful exit status for determining what's wrong with 
their entry (why did it fail specification, for example).

To help decode the exit status, the functions you want to use are:

# In /usr/share/bsdconfig/networking/ipaddr.subr

Function family:

f_dialog_iperror $status $ipv4_addr
f_dialog_ip6error $status $ipv6_addr

As is implied with the _dialog_ in their name, they take the $? exit status 
from the previously mentioned f_validate_*() functions and display a dialog(1) 
error appropriate to what's wrong.

For example, you might see:

ERROR! One or more individual octets within the IPv4 address\n(separated by 
dots) contains one or more invalid characters.\nOctets must contain only the 
characters 0-9.\n\nInvalid IP Address: %s

or

ERROR! The IP address entered has either too few (less than 3), too\nmany (more 
than 8), or not enough segments, separated by colons.\n\nInvalid IPv6 Address: 
%s

And then, in the same function family above (as the *ip[6]error()):

f_dialog_vaildate_ipaddr $ipv4_addr
f_dialog_validate_ipaddr6 $ipv6_addr

These are like:

f_validate_ipaddr $ipv4_addr
f_validate_ipaddr6 $ipv6_addr

Except as implied by the extra _dialog_ in their name, they will actually run 
f_validate_* and then f_dialog_ip[6]error() for you with the result.

Finally, last, but not least...

The process of actually *getting* the values has been simplified too. In the 
same family function (as f_dialog_ip[6]error and f_dialog_validate_ipaddr[6]()) 
is:

f_dialog_input_ipaddr $interface $ipaddr
# $interface is displayed in the prompt text
# $ipaddr is used as default text in the input box

If user doesn't press escape or select cancel, $ipaddr will hold the users 
entry.

This function validates, displays errors, and is an all-around solution if you 
need to prompt the user to enter the info and only proceed if they enter a 
valid entry (the above function is IPv4 centric and supports CIDR notation).

The IPv6 version of the latter (f_dialog_input_ipaddr6) does not yet exist. I'm 
getting there. For now, if you need to prompt for an entry that could be IPv6, 
use the generic f_dialog_input() routine and sanitize it with the 
aforementioned API.
-- 
Cheers,
Devin

_
The information contained in this message is proprietary and/or confidential. 
If you are not the intended recipient, please: (i) delete the message and all 
copies; (ii) do not disclose, distribute or use the message in any manner; and 
(iii) notify the sender immediately. In addition, please be aware that any 
message addressed to our domain is subject to archiving and review by persons 
other than the intended recipient. Thank you.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Assign program call to a key

2013-08-03 Thread jb
Polytropon freebsd at edvax.de writes:

 
 Is there a way to assign a predefined program call to a key
 in X, _independently_ from the window manager or desktop
 environment in use?
 ...

https://wiki.archlinux.org/index.php/Extra_Keyboard_Keys_in_Xorg
It may give you some hints.
jb
 


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


D-Link DUBE100 USB NIC does not work

2013-08-03 Thread Victor Sudakov
Dear Colleagues,

It is written in axe(4) and in the HCL for 9.1 that D-Link DUBE100 is
supported.  I have bought one and the system shows it as 

ugen0.3: product 0x1a02 vendor 0x2001 at usbus0, cfg=0 md=HOST spd=HIGH 
(480Mbps) pwr=ON (200mA)

What am I doing wrong? Why does it not attach a driver to it? Should I
do something else besides plugging the device in for the network
interface to appear?

I am running stable/9 (9.2-BETA2 at the moment).

TIA for any input.

-- 
Victor Sudakov,  VAS4-RIPE, VAS47-RIPN
sip:suda...@sibptus.tomsk.ru
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: D-Link DUBE100 USB NIC does not work

2013-08-03 Thread Waitman Gobble
On Aug 3, 2013 8:05 AM, Victor Sudakov v...@mpeks.tomsk.su wrote:

 Dear Colleagues,

 It is written in axe(4) and in the HCL for 9.1 that D-Link DUBE100 is
 supported.  I have bought one and the system shows it as

 ugen0.3: product 0x1a02 vendor 0x2001 at usbus0, cfg=0 md=HOST spd=HIGH
(480Mbps) pwr=ON (200mA)

 What am I doing wrong? Why does it not attach a driver to it? Should I
 do something else besides plugging the device in for the network
 interface to appear?

 I am running stable/9 (9.2-BETA2 at the moment).

 TIA for any input.

 --
 Victor Sudakov,  VAS4-RIPE, VAS47-RIPN
 sip:suda...@sibptus.tomsk.ru

Hi, did you see the axe(4) man page? Did you put if_axe_load=YES in
loader.conf or build kernel with axe support?

Hope that helps.

Waitman Gobble
San Jose California USA
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: D-Link DUBE100 USB NIC does not work

2013-08-03 Thread Victor Sudakov
Waitman Gobble wrote:
 
  It is written in axe(4) and in the HCL for 9.1 that D-Link DUBE100 is
  supported.  I have bought one and the system shows it as
 
  ugen0.3: product 0x1a02 vendor 0x2001 at usbus0, cfg=0 md=HOST spd=HIGH 
  (480Mbps) pwr=ON (200mA)
 
  What am I doing wrong? Why does it not attach a driver to it? Should I
  do something else besides plugging the device in for the network
  interface to appear?
 
  I am running stable/9 (9.2-BETA2 at the moment).
 
 Hi, did you see the axe(4) man page? 

Yes. I mentioned it in my message.

 Did you put if_axe_load=YES in
 loader.conf or build kernel with axe support?

The GENERIC kernel already has device axe

[sudakov@vas ~] grep axe /sys/amd64/conf/GENERIC
device  axe # ASIX Electronics USB Ethernet
[sudakov@vas ~] 

[root@vas ~] kldload if_axe
kldload: can't load if_axe: Exec format error
[root@vas ~] dmesg | grep axe
module axe already present!
interface axe.1 already present in the KLD 'kernel'!
[root@vas ~] 

-- 
Victor Sudakov,  VAS4-RIPE, VAS47-RIPN
sip:suda...@sibptus.tomsk.ru
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


x11-toolkits/open-motif build issue

2013-08-03 Thread Gary Aitken
Hi all,

I'm running a newly upgraded 9.1.
Did a portmaster -a to rebuild what I had up to a point,
then tried building x11-toolkits/open-motif,
as it is the component which failed when trying to build editors/openoffice-3.

Seeing the same error I was seeing under 9.0.
I suspect this is something screwed up in the environment but haven't a clue
what it is.
It looks like crt1.o is being included in the library build by mistake,
and that's causing the undefined ref to _main.

hints?

Thanks,

Gary


gmake[1]: Entering directory 
`/usr/ports/x11-toolkits/open-motif/work/motif-2.3.4/tools'
Making all in wml
gmake[2]: Entering directory 
`/usr/ports/x11-toolkits/open-motif/work/motif-2.3.4/tools/wml'
/bin/sh ../../libtool  --tag=CC   --mode=link cc  -O2 -pipe 
-fno-strict-aliasing -std=gnu89 -Wall -g -fno-strict-aliasing -Wno-unused 
-Wno-comment -fno-tree-ter -DCSRG_BASED -DXNO_MTSAFE_API -DXNO_MTSAFE_PWDAPI 
-D_THREAD_SAFE -I/usr/local/include/freetype2 -I/usr/local/include  
-L/usr/local/lib -o wmluiltok wmluiltok.o  -lXp -liconv  -L/usr/local/lib -lXft 
-lXrender  -L/usr/local/lib -lXft   -ljpeg -lpng
libtool: link: cc -O2 -pipe -fno-strict-aliasing -std=gnu89 -Wall -g 
-fno-strict-aliasing -Wno-unused -Wno-comment -fno-tree-ter -DCSRG_BASED 
-DXNO_MTSAFE_API -DXNO_MTSAFE_PWDAPI -D_THREAD_SAFE 
-I/usr/local/include/freetype2 -I/usr/local/include -o wmluiltok wmluiltok.o  
-L/usr/local/lib /usr/local/lib/libXp.so /usr/local/lib/libXext.so 
/usr/local/lib/libiconv.so /usr/local/lib/libXft.so 
/usr/local/lib/libfontconfig.so /usr/local/lib/libexpat.so 
/usr/local/lib/libfreetype.so -lz -lbz2 /usr/local/lib/libXrender.so 
/usr/local/lib/libX11.so /usr/local/lib/libxcb.so /usr/local/lib/libXau.so 
/usr/local/lib/libXdmcp.so /usr/local/lib/libpthread-stubs.so -lrpcsvc 
/usr/local/lib/libjpeg.so -lpng -pthread -Wl,-rpath -Wl,/usr/local/lib 
-Wl,-rpath -Wl,/usr/local/lib
/usr/lib/crt1.o: In function `_start':
crt1.c:(.text+0x8a): undefined reference to `main'
gmake[2]: *** [wmluiltok] Error 1
gmake[2]: Leaving directory 
`/usr/ports/x11-toolkits/open-motif/work/motif-2.3.4/tools/wml'
gmake[1]: *** [all-recursive] Error 1
gmake[1]: Leaving directory 
`/usr/ports/x11-toolkits/open-motif/work/motif-2.3.4/tools'
gmake: *** [all-recursive] Error 1
*** [do-build] Error code 1

Stop in /usr/ports/x11-toolkits/open-motif.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Archiving a log file

2013-08-03 Thread Frank Leonhardt

The answer isn't (AFAIK) newsyslog

As a one-off, I need to archive an old log file - say httpd-access.log - 
while its still open. I don't want this to happen automatically and I 
don't want to set up newsyslog or anything like that. And I really don't 
want to mess about with signals to whatever is writing to the file, even 
assuming the writer could respond to them. I can't just rename the file 
as it's open for writing, and there would also be a good chance that 
something will be added to the file while it's being compressed.


What I actually do is:

cp httpd-access.log httpd-access.log-03-Aug-13  : httpd-access.log  
bzip2 httpd-access.log-03-Aug-13


Data might be lost here as something may be added between the cp being 
completed and the file being truncated. It's not the end of the world if 
this happens, but is there a better way? I could always shut down Apache 
for the duration, but I don't want to do that either, so in this case 
I'm happy to take the risk (it's not like I'm likely to miss anything 
that important).


I don't know if this can be relied on as a POSIX thing, but the cp 
command simply(!) issues read() and write() calls until read() fails to 
get any more bytes, so if data is being appended to the file after cp is 
started it'll still be copied. Therefore the window where stuff could be 
written after the copy but before the truncation is shortened, but extant.


So what's the magic utility I don't know about?

Thanks, Frank.


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Archiving a log file

2013-08-03 Thread Dan Nelson
In the last episode (Aug 04), Frank Leonhardt said:
 The answer isn't (AFAIK) newsyslog
 
 As a one-off, I need to archive an old log file - say httpd-access.log -
 while its still open.  I don't want this to happen automatically and I
 don't want to set up newsyslog or anything like that.  And I really don't
 want to mess about with signals to whatever is writing to the file, even
 assuming the writer could respond to them.  I can't just rename the file
 as it's open for writing, and there would also be a good chance that
 something will be added to the file while it's being compressed.
 
 What I actually do is:
 
 cp httpd-access.log httpd-access.log-03-Aug-13  : httpd-access.log   
 bzip2 httpd-access.log-03-Aug-13
 
 Data might be lost here as something may be added between the cp being
 completed and the file being truncated.  It's not the end of the world if
 this happens, but is there a better way?  I could always shut down Apache
 for the duration, but I don't want to do that either, so in this case I'm
 happy to take the risk (it's not like I'm likely to miss anything that
 important).
 
 I don't know if this can be relied on as a POSIX thing, but the cp command
 simply(!) issues read() and write() calls until read() fails to get any
 more bytes, so if data is being appended to the file after cp is started
 it'll still be copied.  Therefore the window where stuff could be written
 after the copy but before the truncation is shortened, but extant.
 
 So what's the magic utility I don't know about?

newsyslog :)   It renames the active logfile to a new name, sends the
process a signal (syslog and SIGHUP by default) letting it know that it
should close and reopen its logfile (creating a new one), then gzips the
renamed file.  In Apache's case, just specify the path to apache's pidfile
in your newsyslog.conf, and everything should just work.  

Don't be afraid of signals.  Without signalling the logging process to
switch to a new logfile, and without suspending the process while you do
your copy, there's always going to be a window where you risk losing logged
data.

-- 
Dan Nelson
dnel...@allantgroup.com
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Archiving a log file

2013-08-03 Thread Frank Leonhardt

On 04/08/2013 00:20, kpn...@pobox.com wrote:

On Sun, Aug 04, 2013 at 12:11:21AM +0100, Frank Leonhardt wrote:

The answer isn't (AFAIK) newsyslog

As a one-off, I need to archive an old log file - say httpd-access.log -
while its still open. I don't want this to happen automatically and I
don't want to set up newsyslog or anything like that. And I really don't
want to mess about with signals to whatever is writing to the file, even
assuming the writer could respond to them. I can't just rename the file
as it's open for writing, and there would also be a good chance that
something will be added to the file while it's being compressed.

What I actually do is:

cp httpd-access.log httpd-access.log-03-Aug-13  : httpd-access.log 
bzip2 httpd-access.log-03-Aug-13

Data might be lost here as something may be added between the cp being
completed and the file being truncated. It's not the end of the world if
this happens, but is there a better way? I could always shut down Apache
for the duration, but I don't want to do that either, so in this case
I'm happy to take the risk (it's not like I'm likely to miss anything
that important).

I don't know if this can be relied on as a POSIX thing, but the cp
command simply(!) issues read() and write() calls until read() fails to
get any more bytes, so if data is being appended to the file after cp is
started it'll still be copied. Therefore the window where stuff could be
written after the copy but before the truncation is shortened, but extant.

So what's the magic utility I don't know about?

How about cronolog? I use it with Apache where Apache logs to cronolog
and cronolog handles the rotating of the logs. No signals. No races.
It even makes a symlink pointing at the newest log file.

It doesn't seem to have a way to compress logs, but you could probably
script up something that wakes up every so often and compresses files
if a newer file exists.


Thanks for the suggestion - I wasn't aware of cronolog. Unfortunately it 
doesn't work on existing log files, only stuff piped to it from the 
start, so it won't help here. I can see it being very handy in other 
situations though. httpd-access.log was just an example of such a file, 
but I'm looking for a general solution.


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Archiving a log file

2013-08-03 Thread mikel king
Do you have logger installed? You coupled pipe your CustomLog into logger which 
will facilitate Apache writing to syslog, in lieu of directly writing the file. 
After some tweaking this should let you use the systems standard log rotation 
schema. 


Something like:

CustomLog | logger -t httpd -p local.info

Cheers,
m

On Aug 3, 2013, at 19:11, Frank Leonhardt freebsd-...@fjl.co.uk wrote:

 The answer isn't (AFAIK) newsyslog
 
 As a one-off, I need to archive an old log file - say httpd-access.log - 
 while its still open. I don't want this to happen automatically and I don't 
 want to set up newsyslog or anything like that. And I really don't want to 
 mess about with signals to whatever is writing to the file, even assuming the 
 writer could respond to them. I can't just rename the file as it's open for 
 writing, and there would also be a good chance that something will be added 
 to the file while it's being compressed.
 
 What I actually do is:
 
 cp httpd-access.log httpd-access.log-03-Aug-13  : httpd-access.log  
 bzip2 httpd-access.log-03-Aug-13
 
 Data might be lost here as something may be added between the cp being 
 completed and the file being truncated. It's not the end of the world if this 
 happens, but is there a better way? I could always shut down Apache for the 
 duration, but I don't want to do that either, so in this case I'm happy to 
 take the risk (it's not like I'm likely to miss anything that important).
 
 I don't know if this can be relied on as a POSIX thing, but the cp command 
 simply(!) issues read() and write() calls until read() fails to get any more 
 bytes, so if data is being appended to the file after cp is started it'll 
 still be copied. Therefore the window where stuff could be written after the 
 copy but before the truncation is shortened, but extant.
 
 So what's the magic utility I don't know about?
 
 Thanks, Frank.
 
 
 ___
 freebsd-questions@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/freebsd-questions
 To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Archiving a log file

2013-08-03 Thread mikel king
On Aug 3, 2013, at 7:11 PM, Frank Leonhardt freebsd-...@fjl.co.uk wrote:

 The answer isn't (AFAIK) newsy slog
 

I did some more digging on the whole log piping thing and apache includes a 
nifty little application called rotatelogs which lives in 
/usr/local/sbin/rotatelogs on my system that I built form the ports. From the 
man page:

NAME 
 rotatelogs - Piped logging program to rotate Apache logs 
SYNOPSIS
rotatelogs [ -l ] [ -f ] logfile rotationtime|filesizeM [ offset ] 
SUMMARY 
rotatelogs is a simple program for use in conjunction with Apache's 
piped logfile feature. It supports rotation based on a time interval or maximum 
size of the log.

It looks pretty simple to use just create your log format directive like:

LogFormat %t \%r\ %s \%{Referer}i\ %b SpecialFormat

CustomLog | /usr/local/sbin/rotatelogs /var/log/httpd-access.log 
86400 SpecialFormat

I hope that helps. I know I shall be experimenting with this one tomorrow. 

Regards,
Mikel King
BSD News Network
http://bsdnews.net
skype: mikel.king
http://twitter.com/mikelking


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org