Site Compatibility Issue

2007-12-21 Thread ASS ELF
I just recently started up a new page and was wondering if it looks okay on
FreBSD. I try to make things compatible for all operating systems, regarding
HTML. It's: http://o.o.angelfire.com/ and/or
http://www.angelfire.com/o.o/index.html I'd greatly appreciate any and all
feedback you could give me on this. Thank you.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: how long does send-pr take to post

2007-12-21 Thread Giorgos Keramidas
On 2007-12-20 17:19, Aryeh M. Friedman [EMAIL PROTECTED] wrote:
 In the past I have not been able to do send-pr but now that I fixed my
 local mail issues all other email apps work... how long should I wait
 for the pr to show up before I decide some kind of error happened.

A few hours for the email notice saying 'we received your report, and it
has been filed as number XXX' is probably reasonable.

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


Re: Redirecting STDOUT

2007-12-21 Thread Derek Ragona

At 08:49 AM 12/21/2007, [EMAIL PROTECTED] wrote:

I am in the process of debugging a script and I would like to have the
output of stdout redirected to a file.

After reading about redirection on the Internet, I was under the
impression the following would redirect stdout to a file, but I cannot
seem to get it to work.

tar -cvzf root.tgz /root  /dev/null 2/home/jay/tarlog

I'm sure it is something simple I am doing wrong, but I am not seeing it.

Thanks for your help.

Jay


In your command line above you are redirecting stdout to /dev/null and 
stderr to your file.


try:

tar -cvzf root.tgz /root  /home/jay/tarlog 21

-Derek

--
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
MailScanner thanks transtec Computers for their support.

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


Redirecting STDOUT

2007-12-21 Thread jhall
I am in the process of debugging a script and I would like to have the
output of stdout redirected to a file.

After reading about redirection on the Internet, I was under the
impression the following would redirect stdout to a file, but I cannot
seem to get it to work.

tar -cvzf root.tgz /root  /dev/null 2/home/jay/tarlog

I'm sure it is something simple I am doing wrong, but I am not seeing it.

Thanks for your help.

Jay


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


Re: Customized FreeBSD CD (was: Can I install Free BSD latest version on my laptop with dual boot?)

2007-12-21 Thread Manolis Kiagias
[EMAIL PROTECTED] wrote:

 Hi,

 Thanks for your immediate response

 Yes, I spend two days and found out there are lot of tips in your
 documentation thanks…

 After compiling the Free BSD Kernel and making some changes on my
 system then how do I make the installable CD/DVD from my source (My
 Free BSD) to distribute to others…

 One more question: Can I use ZFS on Free BSD?

 Cheers,
 B.Manikandan
 Bournemouth, UK
 

Please do not top post.

There are couple of ways to create a custom FreeBSD CD and you will find
them by simply googling. I have not tried any, but this one looks promising:

http://livecd.sourceforge.net/documentos.php

It is available in the ports collection too: /usr/ports/sysutils/livecd

ZFS will be available on FreeBSD 7.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: What priority this app running?

2007-12-21 Thread Unga

--- Pieter de Goeje [EMAIL PROTECTED] wrote:

 On Thursday 20 December 2007, Unga wrote:
  Hi all
 
  $ ps auxl -w | grep amarok
  test   1707  0.0  9.4 61680 48544  ??  S   
 12:29AM
  0:17.29 amarokapp 1003 1   1  20  0
 ksere
 
  Could I check with the list what is the priority
 this
  amarokapp is running?
 Priority isn't shown in the output above. Try 
 $ ps -o pri,ni,rtprio,command -p `pgrep amarok`
 This will display priority, nice value and realtime
 priority (in that order).
 
  The ps man page doesn't show the values for
 priority,
  therefore, what should be the values it should
 display
  for lowest and highest priority (realtime)?
 A lower value means higher priority. Realtime
 priority 0 is as high as you can 
 get. See also rtprio(1).
 

Thanks all for replies.

Priority is still not clear to me.

$ ps -o pri,ni,rtprio,command -p `pgrep amarok`
PRI NI  RTPRIO COMMAND
20  0  normal amarokapp

1) I wonder why there are 3 columns for priority, not
just one?

2) How should I read above? Is it Priority=20, ie.
NI=0, RTPRIO=normal? Does it all mean the same thing,
like the bytes=1048576 and KB=1024 and MB=1?

3) The rtprio(1) says Priority is an integer between
0 and RTP_PRIO_MAX (usually 31).  0 is the highest
priority. But when I run following command:

$ ps aux -o pri,ni,rtprio,command

USER PID %CPU %MEM   VSZ   RSS  TT  STAT STARTED  
   TIME COMMAND  PRI NI  RTPRIO COMMAND

root  10 99.2  0.0 0 8  ??  RL7:40PM  
0:00.00 [idle: cpu1] 171  0 idle:25 [idle: cpu1]

root  26  0.0  0.0 0 8  ??  WL7:40PM  
0:00.02 [irq18: envy24ht -80  0  intr:4 [irq18:
envy24ht

test  1212  0.0  9.3 58544 48176  ??  S 8:06PM  
0:06.15 amarokapp 20  0  normal amarokapp

That is,
 PID  PRI  NI  RTPRIO
  10  171   0  idle:25
  26  -80   0  intr:4
1212   20   0  normal

This shows priority ranges at least from -80 to 171
contrary to the range mentioned in rtprio(1). Does
this means PID=26 has a higher priority than PID=1212?

4) Can a PRI=0 be considered Realtime?

5) What is the meaning of priority=0 in
/etc/login.conf? Realtime?

6) What is the value should I set for priority in
/etc/login.conf if I want Realtime?

Kind Regards
Unga


  

Never miss a thing.  Make Yahoo your home page. 
http://www.yahoo.com/r/hs
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Fw: Can I install Free BSD latest version on my laptop with dual boot?

2007-12-21 Thread manikandan . x . balachandran
Hi,

Thanks for your immediate response

Yes, I spend two days and found out there are lot of tips in your 
documentation thanks?

After compiling the Free BSD Kernel and making some changes on my system 
then how do I make the installable CD/DVD from my source (My Free BSD) to 
distribute to others?

One more question: Can I use ZFS on Free BSD?

Cheers,
B.Manikandan
Bournemouth, UK





Manolis Kiagias [EMAIL PROTECTED]
18/12/2007 07:21 PM
 
To: [EMAIL PROTECTED]
cc: freebsd-questions@freebsd.org
Subject:Re: Fw: Can I install Free BSD latest version on 
my laptop with  dual boot?




[EMAIL PROTECTED] wrote:
 Hi,

 We would like to tune FreeBSD according to our business needs. Please 
 forward some documents for how to compile the Free BSD kernel and how we 

 can deploy our compiled version of Free BSD into a new machine.

 Please help me ASAP

 Cheers,
 B.Manikandan
 UK
 

 

Before actually tuning FreeBSD (or any other OS for that matter) to your
business needs (which we don't know...) you should take more time to
familiarize yourself with the system, perform test installs and so on.
Also don't forget to read the documentation. FreeBSD has an excellent
documentation set, comprising of FAQ, articles and an excellent handbook:

http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/

The handbook will answer most of your questions. Many others you will be
able to answer yourself by experimenting and gaining experience. You
will only get useful answers from the list if your questions are quite
specific and you have done your homework beforehand.



-
This communication is for informational purposes only. It is not
intended as an offer or solicitation for the purchase or sale of
any financial instrument or as an official confirmation of any
transaction. All market prices, data and other information are not
warranted as to completeness or accuracy and are subject to change
without notice. Any comments or statements made herein do not
necessarily reflect those of JPMorgan Chase  Co., its subsidiaries
and affiliates.

This transmission may contain information that is privileged,
confidential, legally privileged, and/or exempt from disclosure
under applicable law. If you are not the intended recipient, you
are hereby notified that any disclosure, copying, distribution, or
use of the information contained herein (including any reliance
thereon) is STRICTLY PROHIBITED. Although this transmission and any
attachments are believed to be free of any virus or other defect
that might affect any computer system into which it is received and
opened, it is the responsibility of the recipient to ensure that it
is virus free and no responsibility is accepted by JPMorgan Chase 
Co., its subsidiaries and affiliates, as applicable, for any loss
or damage arising in any way from its use. If you received this
transmission in error, please immediately contact the sender and
destroy the material in its entirety, whether in electronic or hard
copy format. Thank you.

Please refer to http://www.jpmorgan.com/pages/disclosures for
disclosures relating to UK legal entities.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


My new kernel could not be compiled

2007-12-21 Thread Ray Stinger
I have followed the FreeBSD Handbook, and I just want to add the usb2.0
and sound devices to my kernel. Maybe I canceled too much modules,
though the make error shows the same msg saying ng_prase_int32 type**
My kernel configure file:

-- 
Ray Stinger, nickname lichray
The best way to predict the future is to invent it.
--
let focus = 'computing' in here:
http://let-in.blogspot.com
(let (me Program!)):
http://lichray.blogspot.com
#
# GENERIC -- Generic kernel configuration file for FreeBSD/i386
#
# For more information on this file, please read the handbook section on
# Kernel Configuration Files:
#
#
http://www.FreeBSD.org/doc/en_US.ISO8859-1/books/handbook/kernelconfig-config.html
#
# The handbook is also available locally in /usr/share/doc/handbook
# if you've installed the doc distribution, otherwise always see the
# FreeBSD World Wide Web server (http://www.FreeBSD.org/) for the
# latest information.
#
# An exhaustive list of options and more detailed explanations of the
# device lines is also present in the ../../conf/NOTES and NOTES files.
# If you are in doubt as to the purpose or necessity of a line, check first
# in NOTES.
#
# $FreeBSD: src/sys/i386/conf/GENERIC,v 1.413.2.13 2005/04/02 16:37:58 scottl 
Exp $

machine i386
cpu I486_CPU
cpu I586_CPU
cpu I686_CPU
ident   YUETIME

# To statically compile in device wiring instead of /boot/device.hints
#hints  GENERIC.hints # Default places to look for devices.

options SCHED_4BSD  # 4BSD scheduler
options INET# InterNETworking
#optionsINET6   # IPv6 communications protocols
options FFS # Berkeley Fast Filesystem
options SOFTUPDATES # Enable FFS soft updates support
options UFS_ACL # Support for access control lists
options UFS_DIRHASH # Improve performance on big directories
options MD_ROOT # MD is a potential root device
options NFSCLIENT   # Network Filesystem Client
options NFSSERVER   # Network Filesystem Server
options NFS_ROOT# NFS usable as /, requires NFSCLIENT
#optionsMSDOSFS # MSDOS Filesystem
#optionsCD9660  # ISO 9660 Filesystem
options PROCFS  # Process filesystem (requires PSEUDOFS)
options PSEUDOFS# Pseudo-filesystem framework
options GEOM_GPT# GUID Partition Tables.
options COMPAT_43   # Compatible with BSD 4.3 [KEEP THIS!]
options COMPAT_FREEBSD4 # Compatible with FreeBSD4
options SCSI_DELAY=5000 # Delay (in ms) before probing SCSI
options KTRACE  # ktrace(1) support
options SYSVSHM # SYSV-style shared memory
options SYSVMSG # SYSV-style message queues
options SYSVSEM # SYSV-style semaphores
options _KPOSIX_PRIORITY_SCHEDULING # POSIX P1003_1B real-time 
extensions
options KBD_INSTALL_CDEV# install a CDEV entry in /dev
options AHC_REG_PRETTY_PRINT# Print register bitfields in debug
# output.  Adds ~128k to driver.
options AHD_REG_PRETTY_PRINT# Print register bitfields in debug
# output.  Adds ~215k to driver.
options ADAPTIVE_GIANT  # Giant mutex is adaptive.

device  apic# I/O APIC

# Bus support.  Do not remove isa, even if you have no isa slots
device  isa
device  eisa
device  pci

# Floppy drives
device  fdc

# ATA and ATAPI devices
device  ata
device  atadisk # ATA disk drives
# deviceataraid # ATA RAID drives
device  atapicd # ATAPI CDROM drives
device  atapifd # ATAPI floppy drives
# deviceatapist # ATAPI tape drives
options ATA_STATIC_ID   # Static device numbering

# SCSI Controllers
#device ahb # EISA AHA1742 family
#device ahc # AHA2940 and onboard AIC7xxx devices
#device ahd # AHA39320/29320 and onboard AIC79xx devices
#device amd # AMD 53C974 (Tekram DC-390(T))
#device isp # Qlogic family
#device mpt # LSI-Logic MPT-Fusion
#device ncr # NCR/Symbios Logic
#device sym # NCR/Symbios Logic (newer chipsets + those of 
`ncr')
#device trm # Tekram DC395U/UW/F DC315U adapters

#device adv # Advansys SCSI adapters
#device adw # Advansys wide SCSI adapters
#device aha # 

Re: timekeeping on jail servers

2007-12-21 Thread shinny knight
On Tue, Dec 18, 2007 at 11:02:12AM -0500, Bill Moran wrote:
 In response to Michael W. Lucas :
 
  Hi,
  
  Been searching around without results:
  
  Has anyone come up with a decent way to do timekeeping on a jail
  server? ntpd(8) binds to all addresses, and I'd rather not do a
  ntpdate out of cron.
 
 I'm not entirely sure I comprehend where you're having trouble, Michael,
 but we use openntpd on all our systems, specifically because you can
 tell it what addresses to bind to.

That would be you don't have my problem. Openntpd will solve my
problem.

Thanks for all the pointers, including the dozen or so private ones!

==ml


-- 
Michael W. Lucas [EMAIL PROTECTED], [EMAIL PROTECTED]
http://www.BlackHelicopters.org/~mwlucas/
Now Shipping: Absolute FreeBSD -- http://www.AbsoluteFreeBSD.com
On 5/4/2007, the TSA kept 3 pairs of my soiled undies for security reasons.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]
   
  Hello Michael,
   
  Is there any special reason you do not want to use ntpdate from cron?
  Is working fine for me on FreeBSD jail servers.
   
   
   
   
   
  Best Regards,
   
  Catalin Miclaus
   
   
   
   
  
 

   
-
Looking for last minute shopping deals?  Find them fast with Yahoo! Search.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Redirecting STDOUT

2007-12-21 Thread Michael Lednev
Hello, jhall.

On 21 ??? 2007 ?., 17:49:28 you wrote:

jvn tar -cvzf root.tgz /root  /dev/null 2/home/jay/tarlog

jvn I'm sure it is something simple I am doing wrong, but I am not seeing it.

what is your shell?

-- 
Best regards,
 Michael  mailto:[EMAIL PROTECTED]

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


Re: Redirecting STDOUT

2007-12-21 Thread Girish Venkatachalam
On 14:49:28 Dec 21, [EMAIL PROTECTED] wrote:
 I am in the process of debugging a script and I would like to have the
 output of stdout redirected to a file.
 
 After reading about redirection on the Internet, I was under the
 impression the following would redirect stdout to a file, but I cannot
 seem to get it to work.
 
 tar -cvzf root.tgz /root  /dev/null 2/home/jay/tarlog
 
 I'm sure it is something simple I am doing wrong, but I am not seeing it.

Yes. Very simple indeed.

This is highly shell dependent but on ksh, this command works.

$ tar zcvf root.tgz /root /home/jay/tarlog 2/dev/null

The above command will redirect stderr (fdes 2) to the bit bucket and
stdout to /home/jay/tarlog.

If you wish to redirect both stderr and stdout to a single file, you can
try this command.

$ tar zcvf root.tgz /root /home/jay/tarlog 21

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


/var growing too fast

2007-12-21 Thread Robert Huff

zbigniew szalbot writes:

  I thought I would ask your advice. I only have a 2 GB /var slice
  and space is shrinking fast.

  It may be that something else is eating up available space but I
  am not sure how to measure it. Every day about 1% more of
  available space is taken.

Start by running:

du /var | sort -nr | head -n 50 | more

This will show you the 50 biggest directories.  If you don't
understand why they're the size they are ... that's your first step.


Robert Huff

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


Re: Partitions size for 80GB HDD and 2GB RAM

2007-12-21 Thread Jerry McAllister
On Thu, Dec 20, 2007 at 03:34:30PM -0800, Alexander Rudyk (Akvelon) wrote:

 Thank all of you for really helpful answers.
 
 I am thinking about this configuration (might be helpful for someone in the 
 future)
 
  a:  /  (root)   256 MB
  b:  /swap  4096 MB
  d:  /tmp768 MB
  e:  /usr   8192 MB
  f:  /var   2048 MB
  g:  /home  all the rest.
 
 Think that 8GB will be enough for /usr ports, local and build os from scratch,
 and 2GB for /var - in any case I can symlink some of those to /home

Depends on what things you build.   Some requite huge amounts of space.
Openoffice is one example.  Of course, for many of these, you can get
prebuilt packages.

jerry

 
 So we need about 15GB of free storage only for FreeBSD needs.
 
 Thx
 Alex
 
 
 -Original Message-
 From: Nikola Le??i?? [mailto:[EMAIL PROTECTED]
 Sent: Thursday, December 20, 2007 12:13 PM
 To: Alexander Rudyk (Akvelon)
 Cc: FreeBSD-questions@FreeBSD.org
 Subject: Re: Partitions size for 80GB HDD and 2GB RAM
 
 On Thu, 20 Dec 2007 11:26:41 -0800
 Alexander Rudyk (Akvelon) [EMAIL PROTECTED] wrote:
 
  Nikola,
 
  Thank you for your extender answer. I have two more comments.
 
  Did you consider /var as your email db partition. I really don???t
  know how big will be my mail db on freebsd, but after half of year
  I have about 4GB outlook mail db. So 1GB for /var might be not enough
  in my case.
 
 The hier(7) manpage is very useful to understand the default directory
 structure:
 
   
 http://www.freebsd.org/cgi/man.cgi?query=hierapropos=0sektion=0manpath=FreeBSD+6.2-RELEASEformat=html
 
 As for mail, it depends on how you plan to receive and handle it; if you
 just download mail from pop3 account, it will be stored in your home by
 a mail client (this goes as well for mail you export from Outlook to
 e.g. Thunderbird). For locally (system) delivered mail, /var/spool is
 the default place, but unless you want yo use your laptop as a mail
 server, it's unlikely you will store your mail there.
 
  Having /home as part of /usr is the good point. But in case of backup
  it make sense to have /home as separate partition. What you think
  about this?
 
 Of course it's very useful for backups. I just thought it was useful to
 warn you about how much space /usr/ports could need because the default
 installation procedure on FreeBSD is to compile sources (of thirs
 party applications and of FreeBSD itself).
 
 As a useful example on how much space you might need, here are rough
 sizes on my home desktop computer, used for everyday work. I have ~850
 ports installed.
 
   /usr/ports~2G (with current distfiles and packages that happen
  to be there + you will need at least 2-3G for
  large upgrades, sometimes  10G)
   /usr/local~5G (third party applications + additions such as
  TeXLive = ~1G)
   /usr/home~20G
   -
   /usr total used: ~30G (includes FreeBSD itself + some other smaller
  storages)
 
 If you plan to build FreeBSD itself in the future, then /usr must be
 even bigger. If all this leaves enough room for /home for you, then
 it's certainly very useful to make it separate partition.
 
 --
 Nikola Le??i?? ::  ??

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


Re: /var growing too fast

2007-12-21 Thread zbigniew szalbot

Hello,

Robert Huff pisze:

zbigniew szalbot writes:

  I thought I would ask your advice. I only have a 2 GB /var slice
  and space is shrinking fast.

  It may be that something else is eating up available space but I
  am not sure how to measure it. Every day about 1% more of
  available space is taken.

Start by running:

du /var | sort -nr | head -n 50 | more
  
Great! Thank you. /var/mysql is the biggest. It kind of strange because 
I only have maybe 7MB worth of data on mysql database. I guess these all 
are necesseray files though. I did check on a different machine I have 
access to, mysql dir is even bigger.


Thank you Robert!

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


Re: /var growing too fast

2007-12-21 Thread Jerry McAllister
On Fri, Dec 21, 2007 at 07:09:01AM +0100, zbigniew szalbot wrote:

 Hello,
 
 I thought I would ask your advice. I only have a 2 GB /var slice and 
 space is shrinking fast. I see that most space is taken by /var/db.
 
 $ du -hs /var/db
 1.4G/var/db
 
 $  du -hs /var
 1.7G/var
 
 $ df
 /dev/ad0s1e   2178510 1738396  26583487%/var
 
 Is it possible to release some space from /var/db? I seem to recall that 
 /var/db is pretty important and I better not lose it...

Yes, if you are running some database, it can grow fast.

Do you have a large, catch-all, partition, such as /home?
If go, move /var/db to and make a symlink.

You should be able to copy it all with tar.
Pick a make-sense name for the directory in the new directory such as 'var.db'

Then, in the original /var directory, rename db temporarily - mv db olddb
for example and make the link.ln -s /home/var.db db   (presuming that
you put it in /home)
If it all seems good, then rm the olddb and all should be well.

jerry


 
 It may be that something else is eating up available space but I am not 
 sure how to measure it. Every day about 1% more of available space is taken.
 
 Many thanks for ideas what to do (apart from bying a bigger drive :)
 
 And season greetings to you all!
 
 Zbigniew Szalbot
 ___
 freebsd-questions@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/freebsd-questions
 To unsubscribe, send any mail to [EMAIL PROTECTED]
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: timekeeping on jail servers

2007-12-21 Thread Bill Moran
In response to shinny knight [EMAIL PROTECTED]:
 On Tue, Dec 18, 2007 at 11:02:12AM -0500, Bill Moran wrote:
  In response to Michael W. Lucas :
   
   Been searching around without results:
   
   Has anyone come up with a decent way to do timekeeping on a jail
   server? ntpd(8) binds to all addresses, and I'd rather not do a
   ntpdate out of cron.
  
  I'm not entirely sure I comprehend where you're having trouble, Michael,
  but we use openntpd on all our systems, specifically because you can
  tell it what addresses to bind to.
 
 That would be you don't have my problem. Openntpd will solve my
 problem.
 
 Thanks for all the pointers, including the dozen or so private ones!

   Hello Michael,

   Is there any special reason you do not want to use ntpdate from cron?
   Is working fine for me on FreeBSD jail servers.

The reason that is not recommended is that it results in sudden steps
of the clock.  Occasionally, these steps go backwards.  Software that
is very sensitive to time changes (make processes, database servers,
anything doing calculations WRT time) can break, crash, or work
inaccurately.

ntpd works by speeding up or slowing down the clock to catch up to the
correct time.  As a result, it's much less likely to disturb time-
sensitive applications.  Also, over time ntpd will tune the clock so
that it is actually ticking correctly, unlike the ntpdate in cron
solution.

For example, if your clock cronically ticks 1 second slow every 5
minutes:
* running ntpdate from cron every five minutes will result in a 1 second
  jump every time it runs.
* Running ntpd will result in the kernel speeding up the clock so that
  it actually ticks correctly.

A lot of people new to ntpd think that it's not working because they
start it and their time is still wrong.  If the time is badly wrong when
ntpd starts, it can take quite a while for it to correct it.  If you
have a machine that is frequently turned off, ntpdate should be run at
boot to snap the time into correctness, at which point ntpd will keep it
there.

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


freenx server

2007-12-21 Thread Jack Barnett


Anyone get the freeNX server working from nomachine?

When I try to build it from /usr/ports/net/freenx it says it is broken 
under xorg 7.2


I've upgrade to xorg 7.3.x and modified the make file and it builds 
everything but nxagent, so it fails to `make install`


install: /usr/ports/net/nxserver/work/nx-X11/programs/Xserver/nxagent: 
No such file or directory

*** Error code 71



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


How to get best results from FreeBSD-questions

2007-12-21 Thread Greg Lehey

How to get the best results from FreeBSD questions.
===

Last update $Date: 2005/08/10 02:21:44 $

This is a regular posting to the FreeBSD questions mailing list.  If
you got it in answer to a message you sent, it means that the sender
thinks that at least one of the following things was wrong with your
message:

- You left out a subject line, or the subject line was not appropriate.
- You formatted it in such a way that it was difficult to read.
- You asked more than one unrelated question in one message.
- You sent out a message with an incorrect date, time or time zone.
- You sent out the same message more than once.
- You sent an 'unsubscribe' message to FreeBSD-questions.

If you have done any of these things, there is a good chance that you
will get more than one copy of this message from different people.
Read on, and your next message will be more successful.

This document is also available on the web at
http://www.lemis.com/questions.html.

=

Contents:

I:Introduction
II:   How to unsubscribe from FreeBSD-questions
III:  Should I ask -questions or -hackers?
IV:   How to submit a question to FreeBSD-questions
V:How to answer a question to FreeBSD-questions

I: Introduction
===

This is a regular posting aimed to help both those seeking advice from
FreeBSD-questions (the newcomers), and also those who answer the
questions (the hackers).

   Note that the term hacker has nothing to do with breaking
   into other people's computers.  The correct term for the latter
   activity is cracker, but the popular press hasn't found out
   yet.  The FreeBSD hackers disapprove strongly of cracking
   security, and have nothing to do with it.

In the past, there has been some friction which stems from the
different viewpoints of the two groups.  The newcomers accused the
hackers of being arrogant, stuck-up, and unhelpful, while the hackers
accused the newcomers of being stupid, unable to read plain English,
and expecting everything to be handed to them on a silver platter.  Of
course, there's an element of truth in both these claims, but for the
most part these viewpoints come from a sense of frustration.

In this document, I'd like to do something to relieve this frustration
and help everybody get better results from FreeBSD-questions.  In the
following section, I recommend how to submit a question; after that,
we'll look at how to answer one.

II:  How to unsubscribe from FreeBSD-questions
==

When you subscribed to FreeBSD-questions, you got a welcome message
from [EMAIL PROTECTED]  In this message, amongst
other things, it told you how to unsubscribe.  Here's a typical
message:

  Welcome to the freebsd-questions@freebsd.org mailing list!

If you ever want to unsubscribe or change your options (eg, switch to
or from digest mode, change your password, etc.), visit your
subscription page at:

  http://lists.freebsd.org/mailman/options/freebsd-questions/[EMAIL PROTECTED]
  
(obviously, substitute your mail address for [EMAIL PROTECTED]).  You can
also make such adjustments via email by sending a message to:

  [EMAIL PROTECTED]
  
with the word 'help' in the subject or body (don't include the
quotes), and you will get back a message with instructions.

You must know your password to change your options (including
changing the password, itself) or to unsubscribe.
  
Normally, Mailman will remind you of your freebsd.org mailing list
passwords once every month, although you can disable this if you
prefer.  This reminder will also include instructions on how to
unsubscribe or change your account options.  There is also a button on
your options page that will email your current password to you.

  Here's the general information for the list you've
  subscribed to, in case you don't already have it:

  FREEBSD-QUESTIONS   User questions
  This is the mailing list for questions about FreeBSD.  You should not
  send how to questions to the technical lists unless you consider the
  question to be pretty technical.

Normally, unsubscribing is even simpler than the message suggests: you
don't need to specify your mail ID unless it is different from the one
which you specified when you subscribed.

If Majordomo replies and tells you (incorrectly) that you're not on
the list, this may mean one of two things:

  1.  You have changed your mail ID since you subscribed.  That's where
  keeping the original message from majordomo comes in handy.  For
  example, the sample message above shows my mail ID as
  [EMAIL PROTECTED]  Since then, I have changed it to
  [EMAIL PROTECTED]  If I were to try to remove [EMAIL PROTECTED] from
  the list, it would fail: I would have to specify the name with
  which I joined.

  2.  You're subscribed to a mailing list which is subscribed to
  

Re: Redirecting STDOUT

2007-12-21 Thread jhall
 Hello, jhall.

 On 21 ??? 2007 ?., 17:49:28 you wrote:

 jvn tar -cvzf root.tgz /root  /dev/null 2/home/jay/tarlog

 jvn I'm sure it is something simple I am doing wrong, but I am not seeing
 it.

 what is your shell?

 --
 Best regards,
  Michael  mailto:[EMAIL PROTECTED]


/bin/sh


Jay

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


Re: Redirecting STDOUT

2007-12-21 Thread Michael Lednev
Hello, jhall.

On 21 ??? 2007 ?., 19:59:27 you wrote:

 Hello, jhall.

 On 21 ??? 2007 ?., 17:49:28 you wrote:

 jvn tar -cvzf root.tgz /root  /dev/null 2/home/jay/tarlog

 jvn I'm sure it is something simple I am doing wrong, but I am not seeing
 it.

 what is your shell?

 --
 Best regards,
  Michael  mailto:[EMAIL PROTECTED]


jvn /bin/sh

In that case you only redirecting STDERR to file. As you've been
already told STDOUT will be redirected with

$ command 1file

or

$ command  file

adding 21 will also redirect STDERR to this file

-- 
Best regards,
 Michael  mailto:[EMAIL PROTECTED]

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


Re: Redirecting STDOUT

2007-12-21 Thread jhall
 At 08:49 AM 12/21/2007, [EMAIL PROTECTED] wrote:
I am in the process of debugging a script and I would like to have the
output of stdout redirected to a file.

After reading about redirection on the Internet, I was under the
impression the following would redirect stdout to a file, but I cannot
seem to get it to work.

tar -cvzf root.tgz /root  /dev/null 2/home/jay/tarlog

I'm sure it is something simple I am doing wrong, but I am not seeing it.

Thanks for your help.

Jay

 In your command line above you are redirecting stdout to /dev/null and
 stderr to your file.

 try:

 tar -cvzf root.tgz /root  /home/jay/tarlog 21

When I run the above, I receive the following message.
Ambiguous output redirect.

Any suggestions?  What I found Googling on the message indicates I am
trying to write the output to multiple locations.

I am using the bourne shell.  I am using the right syntax?

Thanks,


Jay

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


The Complete FreeBSD: errata and addenda

2007-12-21 Thread Greg Lehey
The trouble with books is that you can't update them the way you can a web page
or any other online documentation.  The result is that most leading edge
computer books are out of date almost before they are printed.  Unfortunately,
The Complete FreeBSD, published by O'Reilly, is no exception.  Inevitably, a
number of bugs and changes have surfaced.

The Complete FreeBSD has been through a total of five editions, including its
predecessor Installing and Running FreeBSD.  Two of these have been reprinted
with corrections.  I maintain a series of errata pages.  Start at
http://www.lemis.com/errata-4.html to find out how to get the errata
information.

Note also that the book has now been released for free download in PDF
form.  Instead of downloading the changed pages, you may prefer to
download the entire book.  See http://www.lemis.com/grog/Documentation/CFBSD/ 
for more information.

Have you found a problem with the book, or maybe something confusing?
Please let me know: I'm no longer constantly updating it, but I may be
able to help

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


Re: timekeeping on jail servers

2007-12-21 Thread John Webster


--On December 21, 2007 11:23:03 AM -0500 Bill Moran [EMAIL PROTECTED] wrote:

 In response to shinny knight [EMAIL PROTECTED]:
 
 The reason that is not recommended is that it results in sudden steps
 of the clock.  Occasionally, these steps go backwards.  Software that
 is very sensitive to time changes (make processes, database servers,
 anything doing calculations WRT time) can break, crash, or work
 inaccurately.
 


ntpdate -B should slew the time slowly.  (According to the manpage.)


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


Re: Redirecting STDOUT

2007-12-21 Thread Derek Ragona

At 11:12 AM 12/21/2007, [EMAIL PROTECTED] wrote:

 At 08:49 AM 12/21/2007, [EMAIL PROTECTED] wrote:
I am in the process of debugging a script and I would like to have the
output of stdout redirected to a file.

After reading about redirection on the Internet, I was under the
impression the following would redirect stdout to a file, but I cannot
seem to get it to work.

tar -cvzf root.tgz /root  /dev/null 2/home/jay/tarlog

I'm sure it is something simple I am doing wrong, but I am not seeing it.

Thanks for your help.

Jay

 In your command line above you are redirecting stdout to /dev/null and
 stderr to your file.

 try:

 tar -cvzf root.tgz /root  /home/jay/tarlog 21

When I run the above, I receive the following message.
Ambiguous output redirect.

Any suggestions?  What I found Googling on the message indicates I am
trying to write the output to multiple locations.

I am using the bourne shell.  I am using the right syntax?

Thanks,


Jay


tar is a bit different in the syntax, this seems to work:
 tar -f /root.tgz -cvz /root /home/jay/tarlog 21

-Derek

--
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
MailScanner thanks transtec Computers for their support.

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


Re: Redirecting STDOUT

2007-12-21 Thread jhall

 In that case you only redirecting STDERR to file. As you've been
 already told STDOUT will be redirected with

 $ command 1file

 or

 $ command  file

 adding 21 will also redirect STDERR to this file


When I run this as a non-root user it works fine.  But, when running it as
root, it does not produce the expected results.

$ ls -l /fjdkslafjdl 2/home/hallja/test2
And, in the file test2, I see

ls: /fjdkslafjdl: No such file or directory

Running the same command as root, I receive the following results.
# ls -l /fjdkslafjdl 2/home/hallja/test2
ls: /fjdkslafjdl: No such file or directory

And, in /home/hallja/test2 I see the following.
-rw-r--r--  1 root  hallja  0 Dec 21 08:02 2

Why does this not work as root?

Thanks,


Jay

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


Re: timekeeping on jail servers

2007-12-21 Thread Bill Moran
In response to John Webster [EMAIL PROTECTED]:
 
 --On December 21, 2007 11:23:03 AM -0500 Bill Moran [EMAIL PROTECTED] wrote:
 
  In response to shinny knight [EMAIL PROTECTED]:
  
  The reason that is not recommended is that it results in sudden steps
  of the clock.  Occasionally, these steps go backwards.  Software that
  is very sensitive to time changes (make processes, database servers,
  anything doing calculations WRT time) can break, crash, or work
  inaccurately.
 
 ntpdate -B should slew the time slowly.  (According to the manpage.)

Not generally suitable for cron because it can take longer to slew
than it does for the next cron execution to occur, which would then
result in multiple ntpdate programs fighting each other (not sure
what the effect of this would be).

If you ask me, the -B option is available for people who want to
totally hose timekeeping on their system.

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


Re: My new kernel could not be compiled

2007-12-21 Thread Yuri Pankov
On Friday 21 December 2007 16:42:16 Ray Stinger wrote:
 I have followed the FreeBSD Handbook, and I just want to add the usb2.0
 and sound devices to my kernel. Maybe I canceled too much modules,
 though the make error shows the same msg saying ng_prase_int32 type**
 My kernel configure file:

Could you be more verbose than `msg saying ng_prase_int32 type**'? :-)
It's really hard to guess given so little information. Please paste at least 
full compiler line and exact error messages.


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


Re: timekeeping on jail servers

2007-12-21 Thread John Webster


--On Friday, December 21, 2007 13:24:40 -0500 Bill Moran [EMAIL PROTECTED] 
wrote:

 In response to John Webster [EMAIL PROTECTED]:
 
 --On December 21, 2007 11:23:03 AM -0500 Bill Moran [EMAIL PROTECTED] 
 wrote:
 
  In response to shinny knight [EMAIL PROTECTED]:
  
  The reason that is not recommended is that it results in sudden steps
  of the clock.  Occasionally, these steps go backwards.  Software that
  is very sensitive to time changes (make processes, database servers,
  anything doing calculations WRT time) can break, crash, or work
  inaccurately.
 
 ntpdate -B should slew the time slowly.  (According to the manpage.)
 
 Not generally suitable for cron because it can take longer to slew
 than it does for the next cron execution to occur, which would then
 result in multiple ntpdate programs fighting each other (not sure
 what the effect of this would be).
 

If I were doing it I would write a script with locking in order
to ensure multiple jobs don't fight.  Simple.


Happy Holidays!

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


Re: timekeeping on jail servers

2007-12-21 Thread Chuck Swiger

On Dec 21, 2007, at 10:24 AM, Bill Moran wrote:

ntpdate -B should slew the time slowly.  (According to the manpage.)


Not generally suitable for cron because it can take longer to slew
than it does for the next cron execution to occur, which would then
result in multiple ntpdate programs fighting each other (not sure
what the effect of this would be).


ntpdate -B calls adjtime(2) and then exits, rather than the process  
staying around; calling it a second time is fine but it isn't  
especially useful to keep running ntpdate via cron.


One should run ntpd instead unless the system in question is  
desperately short on memory and a ~1MB RSS process is a burden.



If you ask me, the -B option is available for people who want to
totally hose timekeeping on their system.


Somewhat.  :-)

--
-Chuck

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


Re: Redirecting STDOUT

2007-12-21 Thread Dan Busarow


On Dec 21, 2007, at 10:34 AM, [EMAIL PROTECTED] wrote:




In that case you only redirecting STDERR to file. As you've been
already told STDOUT will be redirected with

$ command 1file

or

$ command  file

adding 21 will also redirect STDERR to this file



When I run this as a non-root user it works fine.  But, when  
running it as

root, it does not produce the expected results.

$ ls -l /fjdkslafjdl 2/home/hallja/test2
And, in the file test2, I see

ls: /fjdkslafjdl: No such file or directory

Running the same command as root, I receive the following results.
# ls -l /fjdkslafjdl 2/home/hallja/test2
ls: /fjdkslafjdl: No such file or directory

And, in /home/hallja/test2 I see the following.
-rw-r--r--  1 root  hallja  0 Dec 21 08:02 2

Why does this not work as root?



When you are root type in

  # echo $SHELL

Unless you previously invoked /bin/sh

  # sh

you are almost certainly running csh

Dan

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


Re: timekeeping on jail servers

2007-12-21 Thread Bill Moran
In response to John Webster [EMAIL PROTECTED]:
 
 --On Friday, December 21, 2007 13:24:40 -0500 Bill Moran [EMAIL PROTECTED] 
 wrote:
 
  In response to John Webster [EMAIL PROTECTED]:
  
  --On December 21, 2007 11:23:03 AM -0500 Bill Moran [EMAIL PROTECTED] 
  wrote:
  
   In response to shinny knight [EMAIL PROTECTED]:
   
   The reason that is not recommended is that it results in sudden steps
   of the clock.  Occasionally, these steps go backwards.  Software that
   is very sensitive to time changes (make processes, database servers,
   anything doing calculations WRT time) can break, crash, or work
   inaccurately.
  
  ntpdate -B should slew the time slowly.  (According to the manpage.)
  
  Not generally suitable for cron because it can take longer to slew
  than it does for the next cron execution to occur, which would then
  result in multiple ntpdate programs fighting each other (not sure
  what the effect of this would be).
 
 If I were doing it I would write a script with locking in order
 to ensure multiple jobs don't fight.  Simple.

Umm 

At that point, why not just run ntpd?  You've basically replaced it
with a script anyway.

Besides, it's not that easy.  As Chuck pointed out, ntpdate calls
adjtime() and exits, which means an adjustment might already be in
progress when you you call it again.  I don't know if ntpdate checks
the return pointer from adjtime() to avoid multiple adjustment
requests.

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


Re: timekeeping on jail servers

2007-12-21 Thread John Webster


--On Friday, December 21, 2007 13:51:29 -0500 Bill Moran [EMAIL PROTECTED] 
wrote:

 In response to John Webster [EMAIL PROTECTED]:

  Not generally suitable for cron because it can take longer to slew
  than it does for the next cron execution to occur, which would then
  result in multiple ntpdate programs fighting each other (not sure
  what the effect of this would be).
 
 If I were doing it I would write a script with locking in order
 to ensure multiple jobs don't fight.  Simple.
 
 Umm 
 
 At that point, why not just run ntpd?  You've basically replaced it
 with a script anyway.
 

My suggestions are based on the OP about ntpd binding to everything.


 Besides, it's not that easy.  As Chuck pointed out, ntpdate calls
 adjtime() and exits, which means an adjustment might already be in
 progress when you you call it again.  I don't know if ntpdate checks
 the return pointer from adjtime() to avoid multiple adjustment
 requests.

Just out of curiosity, why run it more that once a day? Or for
that matter every couple of days?





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


Re: ls -l takes a forever to finish.

2007-12-21 Thread Mark Evans

This issue has been resolved.  Thanks for your assistance everyone.
Changing /etc/nsswitch.conf from passwd: compat to read passwd: files 
resolved the issue.



Thanks
Mark

- Original Message - 
From: cpghost [EMAIL PROTECTED]

To: Mark Evans [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Sent: Thursday, December 13, 2007 12:22 PM
Subject: Re: ls -l takes a forever to finish.



On Wed, 12 Dec 2007 13:28:23 -0600
Mark Evans [EMAIL PROTECTED] wrote:


this program seems to have the same issues with it.


[Please don't top post.]

Of course, if ls -lf has those issues, sortls.py will
have them too, because it just runs it and sorts its output
externally with another sorting algorithm. sortls.py speeds
up ls -l considerably for huge (10,000+ entries) directories
by using another sorting algorithm, it doesn't do anything else.

Just to ask again: while you're waiting for ls -lf, what
does top say? Is that process accumulating CPU time, or
is it just sitting around waiting, waiting, waiting...?
Are you using NFS or another file system where stat(2) is
expensive?


Thanks
Mark


- Original Message - 
From: cpghost [EMAIL PROTECTED]

To: Bill Moran [EMAIL PROTECTED]
Cc: Wojciech Puchar [EMAIL PROTECTED];
[EMAIL PROTECTED]; Mark Evans [EMAIL PROTECTED]
Sent: Thursday, November 29, 2007 8:42 AM
Subject: Re: ls -l takes a forever to finish.


 On Thu, 29 Nov 2007 08:42:44 -0500
 Bill Moran [EMAIL PROTECTED] wrote:

 In response to Wojciech Puchar [EMAIL PROTECTED]:

   ls | wc
 
  strange. i did
 
  [EMAIL PROTECTED] ~/b]$ a=0;while [ $a -lt 1 ];do mkdir
  $a;a=$[a+1];done
 
  completed 25 seconds on 1Ghz CPU
 
  ls takes 0.1 seconds user time, ls -l takes 0.3 second user time.
 
  unless you have 486/33 or slower system there is something wrong.

 Another possible scenario is that the directory is badly
 fragmented. Unless something has changed since I last researched
 this (which is possible) FreeBSD doesn't manage directory
 fragmentation during use. If you're constantly adding and removing
 files, it's possible that the directory entry is such a mess that
 it takes ls a long time to process it.

 Yes, that's also possible. But sorting is really the culprit here:
 it *is* possible to create a directory with filenames in such a way
 that it triggers Quicksort's O(N^2) worst case instead of O(N log
 N).

 The following Python (2.5) program calls ls -lf and sorts its
 output with Python's own stable sort() routine (which is NOT
 qsort(3)). On a directory with 44,000 entries, it runs orders of
 magnitude faster than ls -l, even though it has to use the
 decorate-sort-undecorate idiom to sort the output according
 according the filename, and it is interpreted rather than compiled!

 I guess that replacing qsort(3) in
 /usr/src/lib/libc/gen/fts.c:fts_sort()
 with another sort algorithm which doesn't
 expose this anomaly would solve that problem.


- cut here -- cut here 
#!/usr/bin/env python
# sortls.py -- sort output of ls -lf with python's stable sort routine.

import os

def sort_ls_lf(path):
   Sort the output of ls -lf path
   os.chdir(path)
   lines = os.popen(ls -lf, r).readlines()
   dsu = [ (line.split()[-1], line) for line in lines ]
   dsu.sort()
   return ''.join(tupl[1] for tupl in dsu)

if __name__ == '__main__':
   import sys
   if len(sys.argv)  2:
   print sys.stderr, Usage:, sys.argv[0], path
   sys.exit(1)
   path = sys.argv[1]

   try:
   print sort_ls_lf(path)
   except IOError:
   pass   # silently absorb broken pipe and other errors
- cut here -- cut here 

-cpghost.

--
Cordula's Web. http://www.cordula.ws/


--
Internal Virus Database is out-of-date.
Checked by AVG Free Edition.
Version: 7.5.446 / Virus Database: 268.18.25/744 - Release Date: 4/3/2007 
5:32 AM





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


Re: timekeeping on jail servers

2007-12-21 Thread Bill Moran
In response to John Webster [EMAIL PROTECTED]:
 
 --On Friday, December 21, 2007 13:51:29 -0500 Bill Moran [EMAIL PROTECTED] 
 wrote:
 
  In response to John Webster [EMAIL PROTECTED]:
 
   Not generally suitable for cron because it can take longer to slew
   than it does for the next cron execution to occur, which would then
   result in multiple ntpdate programs fighting each other (not sure
   what the effect of this would be).
  
  If I were doing it I would write a script with locking in order
  to ensure multiple jobs don't fight.  Simple.
  
  Umm 
  
  At that point, why not just run ntpd?  You've basically replaced it
  with a script anyway.
  
 
 My suggestions are based on the OP about ntpd binding to everything.
 
 
  Besides, it's not that easy.  As Chuck pointed out, ntpdate calls
  adjtime() and exits, which means an adjustment might already be in
  progress when you you call it again.  I don't know if ntpdate checks
  the return pointer from adjtime() to avoid multiple adjustment
  requests.
 
 Just out of curiosity, why run it more that once a day? Or for
 that matter every couple of days?

There is the matter of how accurate does your time really need to be?

I worked a place where many computers were used for employees to clock
in/clock out.  Synchronizing time once a day, the clocks would drift
enough that employees who showed up on time and left on time would
appear to have arrived late and/or left early (up to 5 minutes a day
drift).

Of course, this is hardware-dependent and even environmentally dependent
(computers connected to clean power sources with consistent environmental
temperature seem to keep more accurate time in my experience)

Other common applications are even more sensitive.  If you run NFS or
other file sharing, you can run into all sorts of ugliness if time skews
more than a few seconds.  Web applications can be notoriously buggy if
either the server or the client is off by more than a few seconds.

With all those potential problems looming, why would you use anything
other than a full-blown ntp daemon?  I just can't see the excuse for
making up other solutions.

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


hangs instead of reboots on HP s3220n

2007-12-21 Thread Jeffrey Goldberg

I have an HP s3220n which will boot just fine, but won't reboot.

I noticed this first with the OEM Vista that I played with for a bit  
before starting to install FreeBSD, but didn't pay much attention to  
it then.


Now when I do a

   shutdown -r now

I get a proper shutdown with the last line on the console saying

  Rebooting

The power stays on, but the machine just hangs at that point.

I looked through BIOS settings and all that I found that was possibly  
meaningful was to reboot after power failure, which I've enabled.  But  
that doesn't help.


Although I think that the problem is well before the OS plays any  
role, the system is running 7.0 Beta 4.  This happened with the  
GENERIC amd64 kernel as well as with my custom one.


This machine will be tucked away in a closet and I don't want to hold  
the power switch to get it to reboot.


Any suggestions would be welcome.  And if I didn't provide enough  
information, just let me know what y'all need.


Cheers,

-j



--
Jeffrey Goldberghttp://www.goldmark.org/jeff/

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


Re: hangs instead of reboots on HP s3220n

2007-12-21 Thread Jeffrey Goldberg

On Dec 21, 2007, at 3:26 PM, Jeffrey Goldberg wrote:


I have an HP s3220n which will boot just fine, but won't reboot [...]



I get a proper shutdown with the last line on the console saying

 Rebooting

The power stays on, but the machine just hangs at that point.


Never mind.  It just takes a really long time before anything visible  
happens on the monitor.  At least a minute, though less than 10  
minutes.  (I waited one full minute and then I left the room,  
returning 10 minutes later.)  Next time I reboot, I'll time it properly.


-j


--
Jeffrey Goldberghttp://www.goldmark.org/jeff/

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


amd64 native boot loader?

2007-12-21 Thread snowcrash+freebsd
hi,

i've FBSD/amd64 62Rp9 installed.  kernel  world are my own builds
from latest cvsup.

on boot I see:

FreeBSD/i386 bootstrap loader

odd.  i'd expect a native loader ...

checking in,

  /usr/src/sys/boot   ls
Makefile  alpha/arm/  efi/  forth/ia64/ pc98/
   sparc64/
READMEarc/  common/   ficl/ i386/ ofw/  powerpc/

other arches seem to be there ... just not amd64.

where's the src for the amd64?

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


FreeBSD 6.3 Release?

2007-12-21 Thread Julian Bolivar


Hi everyone,

Mi question is because checking the FreeBSD 6.3  Release schedule, I note that the 
version 6.3 is upcoming, but the RC2 wan't released, anyone know if this 
schedule is updated or is in time?


Thanks and Regards,

---
  Julian Bolivar








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


which cputype for Althon 64 X2 Dual Core

2007-12-21 Thread Jeffrey Goldberg
I'm building a new server with 7.0 BETA4 (it will track stable) with  
the following CPU


CPU: AMD Athlon(tm) 64 X2 Dual Core Processor 5000+ (2600.02-MHz K8- 
class CPU)

  Origin = AuthenticAMD  Id = 0x60fb1  Stepping = 1
   
Features 
= 
0x178bfbff 
 
FPU 
,VME 
,DE 
,PSE 
,TSC 
,MSR 
,PAE 
,MCE 
,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CLFLUSH,MMX,FXSR,SSE,SSE2,HTT

  Features2=0x2001SSE3,CX16
  AMD Features=0xea500800SYSCALL,NX,MMX+,FFXSR,RDTSCP,LM,3DNow!+, 
3DNow!

  AMD Features2=0x11fLAHF,CMP,SVM,ExtAPIC,CR8,Prefetch
  Cores per package: 2

What optimizations should I make in make.conf?

The example make.conf says

  AMD64 architecture: opteron, athlon64, nocona, prescott, core2

But I don't know whether althon64 or core2 would be the safest and  
most appropriate.


Also GENERIC for amd64 lists

cpuHAMMER

is that the best (only) choice?  And if not, where can I find a list  
of alternatives?  I didn't find anything in the NOTES files telling me  
what was available.


-j


--
Jeffrey Goldberghttp://www.goldmark.org/jeff/

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


Re: which cputype for Althon 64 X2 Dual Core

2007-12-21 Thread Chuck Swiger

On Dec 21, 2007, at 4:33 PM, Jeffrey Goldberg wrote:
I'm building a new server with 7.0 BETA4 (it will track stable) with  
the following CPU


CPU: AMD Athlon(tm) 64 X2 Dual Core Processor 5000+ (2600.02-MHz K8- 
class CPU)

[ ... ]


What optimizations should I make in make.conf?


A reasonable starting point is no special optimizations, and simply  
disable debug options like WITNESS, INVARIANTS, etc.


If you plan to go beyond that, you'll need to start by doing some  
benchmarks before and after setting something like the CPU  
architecture that the compiler should tune for, and see whether you  
actually get any significant differences.



The example make.conf says

 AMD64 architecture: opteron, athlon64, nocona, prescott, core2

But I don't know whether althon64 or core2 would be the safest and  
most appropriate.


Also GENERIC for amd64 lists

   cpuHAMMER

is that the best (only) choice?


Yes, as far as AMD64 code goes.  You could always switch down to  
running in 32-bit mode, though.


--
-Chuck

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


TCP window scaling 14

2007-12-21 Thread Darren Spruell
I have a FreeBSD host which I noticed recently triggering some snort
decoder alerts due to using a TCP window scaling (rfc1323) value of
15. The decoder is tripping because anything greater than 14 is
considered invalid. This text from RFC seems to support it:

Since the max window is 2**S (where S is the scaling shift count)
times at most 2**16 - 1 (the maximum unscaled window), the maximum
window is guaranteed to be  2*30 if S = 14.  Thus, the shift
count must be limited to 14 (which allows windows of 2**30 = 1
Gbyte).  If a Window Scale option is received with a shift.cnt
value exceeding 14, the TCP should log the error but use 14
instead of the specified value.

http://www.networksorcery.com/enp/protocol/tcp/option003.htm suggests
the option should only be set on a SYN packet.

Packet data:

11:41:18.424938 IP (tos 0x0, ttl  46, id 58935, offset 0, flags
[none], proto: TCP (6), length: 60) 137.160.241.90.34223 
165.195.64.61.1: FP, cksum 0x0900 (correct), 1645233436:1645233436(0)
win 65535 urg 0 wscale 15,nop,mss 265,timestamp 4294967295 0,sackOK
0x:  4500 003c e637  2e06 4589 89a0 f15a  E...7EZ
0x0010:  a5c3 403d 85af 0001 6210 451c 86c4 20ed  [EMAIL PROTECTED]
0x0020:  a029  0900  0303 0f01 0204 0109  .)..
0x0030:  080a     0402

This packet was generated during a probe of a remote systems echo
service using nc(1). It may have come when the ctrl+c was issued.

net.inet.tcp.rfc1323 is enabled.

The following are sysctl changes in effect on the system:

kern.ipc.shmmax=67108864
kern.ipc.shmall=32768
vfs.usermount=1
net.inet.tcp.sendspace=65536
net.inet.tcp.recvspace=65536
kern.ipc.nmbclusters=32768

So, is it indeed wrong for FreeBSD to set a window scale value of 15
or on a non-SYN? Any problems to take care of?

DS



Copyright (c) 1992-2007 The FreeBSD Project.
Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994
The Regents of the University of California. All rights reserved.
FreeBSD is a registered trademark of The FreeBSD Foundation.
FreeBSD 6.3-PRERELEASE #0: Fri Nov 30 16:05:54 MST 2007
[EMAIL PROTECTED]:/usr/obj/usr/src/sys/SMP
Timecounter i8254 frequency 1193182 Hz quality 0
CPU: Intel(R) Xeon(R) CPU   E5345  @ 2.33GHz (2327.51-MHz 686-class CPU)
  Origin = GenuineIntel  Id = 0x6f7  Stepping = 7
  
Features=0xbfebfbffFPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CLFLUSH,DTS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE
  Features2=0x4e3bdSSE3,RSVD2,MON,DS_CPL,VMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,DCA
  AMD Features=0x2010NX,LM
  AMD Features2=0x1LAHF
  Cores per package: 4
real memory  = 3219169280 (3070 MB)
avail memory = 3144863744 (2999 MB)
ACPI APIC Table: DELL   B8K
FreeBSD/SMP: Multiprocessor System Detected: 8 CPUs
 cpu0 (BSP): APIC ID:  0
 cpu1 (AP): APIC ID:  1
 cpu2 (AP): APIC ID:  2
 cpu3 (AP): APIC ID:  3
 cpu4 (AP): APIC ID:  4
 cpu5 (AP): APIC ID:  5
 cpu6 (AP): APIC ID:  6
 cpu7 (AP): APIC ID:  7
ioapic0: Changing APIC ID to 8
ioapic1: Changing APIC ID to 9
ioapic0 Version 2.0 irqs 0-23 on motherboard
ioapic1 Version 2.0 irqs 24-47 on motherboard
kbd1 at kbdmux0
netsmb_dev: loaded
ath_hal: 0.9.20.3 (AR5210, AR5211, AR5212, RF5111, RF5112, RF2413, RF5413)
acpi0: DELL B8K on motherboard
acpi0: Power Button (fixed)
Timecounter ACPI-safe frequency 3579545 Hz quality 850
acpi_timer0: 24-bit timer at 3.579545MHz port 0x808-0x80b on acpi0
acpi_hpet0: High Precision Event Timer iomem 0xfed0-0xfed003ff on acpi0
Timecounter HPET frequency 14318180 Hz quality 900
cpu0: ACPI CPU on acpi0
cpu1: ACPI CPU on acpi0
cpu2: ACPI CPU on acpi0
cpu3: ACPI CPU on acpi0
cpu4: ACPI CPU on acpi0
cpu5: ACPI CPU on acpi0
cpu6: ACPI CPU on acpi0
cpu7: ACPI CPU on acpi0
acpi_button0: Power Button on acpi0
pcib0: ACPI Host-PCI bridge port 0xcf8-0xcff on acpi0
pci0: ACPI PCI bus on pcib0
pcib1: ACPI PCI-PCI bridge at device 2.0 on pci0
pci1: ACPI PCI bus on pcib1
pcib2: ACPI PCI-PCI bridge irq 16 at device 0.0 on pci1
pci2: ACPI PCI bus on pcib2
pcib3: ACPI PCI-PCI bridge irq 16 at device 0.0 on pci2
pci3: ACPI PCI bus on pcib3
pcib4: PCI-PCI bridge irq 16 at device 1.0 on pci2
pci4: PCI bus on pcib4
pcib5: ACPI PCI-PCI bridge at device 0.3 on pci1
pci5: ACPI PCI bus on pcib5
fwohci0: Lucent FW322/323 mem 0xdceff000-0xdcef irq 26 at device
5.0 on pci5
fwohci0: OHCI version 1.0 (ROM=1)
fwohci0: No. of Isochronous channels is 8.
fwohci0: EUI64 00:00:d1:00:80:35:7a:57
fwohci0: Phy 1394a available S400, 3 ports.
fwohci0: Link S400, max_rec 2048 bytes.
firewire0: IEEE1394(FireWire) bus on fwohci0
fwe0: Ethernet over FireWire on firewire0
if_fwe0: Fake Ethernet address: 02:00:d1:35:7a:57
fwe0: Ethernet address: 02:00:d1:35:7a:57
fwe0: if_start running deferred for Giant
sbp0: SBP-2/SCSI over FireWire on firewire0
fwohci0: Initiate bus reset
fwohci0: BUS reset
fwohci0: node_id=0xc800ffc0, gen=1, CYCLEMASTER mode
firewire0: 1 nodes, 

snd_hda on amd64 - exec format error

2007-12-21 Thread Steve Franks
This is not a priority, but I'm suprised that both the downloaded
(ariff?) and the built-from-source snd*.ko files give me a:

kldload: can't load snd_hda: Exec format error

When I try to load them...guess my kernel is out of date with the
latest 6.2-stable source?

Best,

Steve

6.2 - amd64

aire# dmesg
Copyright (c) 1992-2007 The FreeBSD Project.
Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994
The Regents of the University of California. All rights reserved.
FreeBSD is a registered trademark of The FreeBSD Foundation.
FreeBSD 6.2-RELEASE #0: Fri Jan 12 08:32:24 UTC 2007
[EMAIL PROTECTED]:/usr/obj/usr/src/sys/GENERIC
Timecounter i8254 frequency 1193182 Hz quality 0
CPU: Intel(R) Celeron(R) CPU  440  @ 2.00GHz (1995.01-MHz K8-class CPU)
  Origin = GenuineIntel  Id = 0x10661  Stepping = 1
  
Features=0xafebfbffFPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CLFLUSH,DTS,ACPI,MMX,FXSR,SSE,SSE2,SS,TM,PBE
  Features2=0xe31dSSE3,RSVD2,MON,DS_CPL,TM2,b9,CX16,b14,b15
  AMD Features=0x20100800SYSCALL,NX,LM
  AMD Features2=0x1LAHF
real memory  = 1064173568 (1014 MB)
avail memory = 1015042048 (968 MB)
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: which cputype for Althon 64 X2 Dual Core

2007-12-21 Thread Jeffrey Goldberg
First of all, thank you very much for your response.  I have some  
follow up questions below.


On Dec 21, 2007, at 6:45 PM, Chuck Swiger wrote:


On Dec 21, 2007, at 4:33 PM, Jeffrey Goldberg wrote:



What optimizations should I make in make.conf?


A reasonable starting point is no special optimizations, and simply  
disable debug options like WITNESS, INVARIANTS, etc.


I didn't see mention of these in the example make.conf so I don't know  
how to disable those if they are enabled in the first place.


If you plan to go beyond that, you'll need to start by doing some  
benchmarks [...]


I'm after the low hanging fruit and I don't really have the  
inclination to do such extensive tuning.  I was just wondering if  
there is anything obvious.



The example make.conf says

AMD64 architecture: opteron, athlon64, nocona, prescott, core2

But I don't know whether althon64 or core2 would be the safest and  
most appropriate.


Also GENERIC for amd64 lists

  cpuHAMMER

is that the best (only) choice?


Yes, as far as AMD64 code goes.  You could always switch down to  
running in 32-bit mode, though.


That answer the question for the kernel configuration.  But what  
should I put in make.conf as cputype?  Right now, I've just left it  
unspecified.


I started a make buildworld and was surprised to see that it is using

  -O2 -fno-strict-aliasing -pipe

even though I didn't tell it to do so.  -O2 sounds like an odd default  
when it appears to be recommended against.


Where should I look for the defaults?

Cheers,

-j

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


Re: Redirecting STDOUT

2007-12-21 Thread Michael Lednev
Hello, jhall.

On 21 ??? 2007 ?., 20:34:52 you wrote:

jvn When I run this as a non-root user it works fine.  But, when running it as
jvn root, it does not produce the expected results.

jvn $ ls -l /fjdkslafjdl 2/home/hallja/test2
jvn And, in the file test2, I see

jvn ls: /fjdkslafjdl: No such file or directory

jvn Running the same command as root, I receive the following results.
jvn # ls -l /fjdkslafjdl 2/home/hallja/test2
jvn ls: /fjdkslafjdl: No such file or directory

jvn And, in /home/hallja/test2 I see the following.
jvn -rw-r--r--  1 root  hallja  0 Dec 21 08:02 2

jvn Why does this not work as root?

Because default shell for root is csh. Try this

# command  file

this will redirect both STDERR and STDOUT to file

-- 
Best regards,
 Michael  mailto:[EMAIL PROTECTED]

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