Re: Can't see second CPU in FreeBSD 5.4-p6

2005-09-02 Thread joseph kacmarcik

 Hyperbollocks is disabled by default.

 See /usr/src/UPDATING entry for 20050513:

  Intel Hyper-Threading is now disabled by default due to a
  security issue, but can be re-enabled by setting the
  machdep.hyperthreading_allowed tunable in /boot/loader.conf.

ah, thanks, that works. simple fixes make me happy. (:

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


Can't see second CPU in FreeBSD 5.4-p6

2005-09-01 Thread joseph kacmarcik
hello's!

i've recently installed freebsd 5.4 and patched up to p6. since the
install and up to this patch level, i'm not certain the second cpu
(hyperthreading, not physical cpu) is being used. i guess it could just be
top not showing it, cuz it's in my kernel and in dmesg.

relevant kernel lines are:
options SCHED_4BSD
options SMP
device  apic

and relevant dmesg output is:
CPU: Intel(R) Pentium(R) 4 CPU 2.80GHz (2795.24-MHz 686-class CPU)
  Hyperthreading: 2 logical CPUs
FreeBSD/SMP: Multiprocessor System Detected: 2 CPUs
 cpu0 (BSP): APIC ID:  0
 cpu1 (AP): APIC ID:  1
cpu0: ACPI CPU on acpi0
cpu1: ACPI CPU on acpi0
SMP: AP CPU #1 Launched!


when using top, i always see CPU0, and the column under 'C' is always 0.

is there another tool i can use to see cpu scheduling or am i missing
something obvious (or obscure)?

for the record, i've tried more than one cpu, and freebsd 5.2.1 was able
to see and use two cpu's with the same hardware.

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


Re: Help Renaming Multple Files

2005-03-07 Thread joseph kacmarcik

 I need help figuring out how to rename multple files. The files are
 named like reports_abcdef_MMDD.dat, reports_hijklm_MMDD.dat,
 and reports_nopqrs_MMDD.dat. Here is an example.
 
 Original Filename: reports_abcdef_MMDD.dat
 New Filename: abcdef_MMDD.dat
 
 Let me know how I can do this. Thanks.

there are plenty of methods for this. one is:

for file in `ls -1 /path/to/files`; do
mv $file `echo $file | sed -e 's/^reports_//g'`
done

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


Re: mystery /var space usage

2005-01-27 Thread joseph kacmarcik

 /dev/amrd0s1e   9.8G   4.8G   4.2G53%/var
 
 A du -h of /var shows a total of 616M data only. First thing that came
 to mind is some process which is holding onto data so I tried
 restarting various daemons - cyrus, imapd, exim, apache and still no
 change. I've checked with fstat and lsof to see if I can see anything
 suspicious but nothing out of the ordinary shows up.

sounds like the maillog. have you tried restarting syslogd or whatever process
you have that writes to your maillog?

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


Re: ssh file transfers - how to?

2005-01-09 Thread joseph kacmarcik

 For purposes of discussion, I'm logged into the distant machine
 as [EMAIL PROTECTED] I'm logged in to the directory /www/jay
 and my localmachine directory (now empty) is /home/www/jay. I want
 everything in the www/jay directory on distantmachine to be copied
 as the home/www/jay directory on localmachine.

this depends whether you want a backup or if you want to have a live copy, there
are a few ways (more on that later).

for a backup, you could (test first please):
ssh remotehost tar cf - /www/jay  /path/to/tarfile

or for live copy, two methods would be:
ssh remotehost tar cf - /www/jay | tar -C /home/www/jay -xf -
scp -pr remotehost:/www/jay /home/www/jay

 My follow-on question is -- Is there a way to synchronize the local
 machine with the distant machine if changes are made on the distant
 machine, and vice-versa, on a generic basis, i.e. distantmachine
 is now the master, correct localmachine to agree?

if you're trying to get a working copy and not backup, use rsync. this would be
much easier, and it's easy to make it bi-directional (or more).

there are many ways to do this, one is:
rsync -azvprt -e ssh [EMAIL PROTECTED]:/www/jay /home/www

you could use -n and --progress when you're doing the debugging getting it right
for your situation and environment.

you'll still be transporting over ssh, but IMO rsync is a better choice.

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


umount gpt partitions

2005-01-07 Thread joseph kacmarcik

hello's!

forgive me if i've missed something obvious, am feeling flu-like but need to get
a project done.

i'm using freebsd 5.3 with gpt partitions to get filesystems more than 2TB, but
when i umount and mount again, i always get: 'WARNING: /filesystem was not
properly dismounted'.

should i do something other than umount for gpt filesystems?

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


Re: nic aggregation/teaming (AFT or similar)

2005-01-06 Thread joseph kacmarcik

 Has there been any developments with this? We are using AFT with dual
 intel nics for switch redundancy on Linux boxes. I really want to try
 and move to FreeBSD, and this is the only major issue that I can see.

if you're looking for single-path redundancy and not increased throughput, you
could use CARP (patches are here: http://people.freebsd.org/~mlaier/CARP/).

the patches apply cleanly to 5.x, and seem to work just fine. if you need more
information, check the list archives.

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


Re: grep help

2005-01-05 Thread joseph kacmarcik

 grep ^[^1.2.3.4]*$ logfile.log

to not match, use: grep -v 1.2.3.4 logfile.log

-v, --invert-match
Invert the sense of matching, to select non-matching lines.

when there are multiple patterns you don't want to see, try:

egrep -v '1.2.3.4|5.6.7.8' logfile.log

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


Re: Cheap NAS using FreeBSD - practical considerations?

2004-12-27 Thread joseph kacmarcik

 Let's say that, as fine as NetApps are, I can't afford their prices. So I
 set up a FreeBSD box with a whole lot of disk attached and use that as
 network-attached storage, serving files by NFS, with gigabit ethernet.
 
 Setting up such a box is trivially easy. But what are the practical
 considerations? Have any of you done this, or know anyone who has? Does
 serving stay at wire speed? Recommendations for motherboards or
 peripherals?

freebsd is a fine choice for this application. of course your performance will
vary depending on what you're running on the clients; http, database, etc.

personally, i'd run off-board raid controllers for your shared storage. leaving
the OS on the motherboard is fine. 3ware, adaptec (aac chip, not asr) can be
controlled via cmdline on freebsd (3ware has 3dm, gui manager). this will reduce
contention on the motherboard.

if you're running a variety of applications on the clients and you have the
resources on the nfs machine, create seperate raid arrays for each with fitting
performance-to-redundancy ratio. ie; raid-50 for web storage to get increased
capacity, raid-10 for database to get slightly increased performance.

i've found these nfs mount options to give the best performance in my
environment: tcp,rsize=32768,wsize=32768. the mount options are suitable for
freebsd, linux and solaris. if you have linux clients, use kernel 2.6.x.

be sure to start enough nfs servers, and monitor the nfs server with nfsstat. it
might be a good idea to graph the various numbers of nfsstat output, so you can
recognize trends and understand your storage infrastructure.

you'll likely notice that freebsd can maintain saturating it's network. if you
have dual-ethernet (or more), you could use an alias IP on the second nic for
the nfs clients, or use multiple alias IP's dedicated to the various
applications. you'll much more easily spot capacity and performance issues in
regards to each application by doing so.

currently, i'm serving @30 nfs clients running freebsd-amd64 on a supermicro
X6DH8-XG2, two 3.6GHz Xeon, 4GB ram, 2x 3ware 9500s-12MI, 1.8TB RAID-50 array
for web/images, and a @300GB RAID-10 array for mysql.

if you have the time, try using bonnie++ (or some other benchmarking utility) on
a few clients concurrently, and watch cpu, memory and disk usage on the nfs
server. bsdsar will record the host data for later research.

depending on filesystem size and server speed, you could be well served by using
freebsd's mksnap_ffs; taking snapshots similar to the netapp.

good luck and have fun!
joe
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]