Re: check variable content size in sh script

2013-05-18 Thread Quartz
I say this from a FreeBSD context. It may entirely be possible that a Linux distro uses bash in /bin/sh Yes. For most (all?) linux distros as well as osx, /bin/sh is actually bash. When I say "emulation mode" I mean running a script with a "#!/bin/sh" header on a system that doesn't have a rea

problems with port upgrade consistency using portsnap

2013-05-18 Thread fddi
Hello, I am using portsnap to update my port collection on FreeBSD 9.1 the first time I ran it a few weeks ago I did| || |||portsnap fetch| || |and then portsnap exctract then I did a crontab script to update ports every night 0 3 * * * /usr/sbin/portsnap -I cron update && pkg_version -vIL=

Re: netgraph network setup for jail(8) vnet jails.

2013-05-18 Thread Teske, Devin
On May 18, 2013, at 5:51 PM, Joe wrote: Teske, Devin wrote: Sorry for top-post, but just wanted to add a quick note: The output of "ngctl dot" would be very helpful to others in debugging your setup. graph netgraph { edge [ weight = 1.0 ]; node [ shape = record, fontsize = 12 ] { "1" [ label =

Re: List Spam Filtering

2013-05-18 Thread RW
On Fri, 17 May 2013 09:15:35 -0400 Jerry wrote: > On Fri, 17 May 2013 14:03:01 +0100 > RW articulated: > > > On Fri, 17 May 2013 08:45:29 -0400 > > Jerry wrote: > > > > > On Fri, 17 May 2013 13:19:32 +0100 > > > RW articulated: > > > > > > > On Fri, 17 May 2013 12:54:29 +0100 > > > > Bruce Cran

Re: netgraph network setup for jail(8) vnet jails.

2013-05-18 Thread Joe
Teske, Devin wrote: Sorry for top-post, but just wanted to add a quick note: The output of "ngctl dot" would be very helpful to others in debugging your setup. graph netgraph { edge [ weight = 1.0 ]; node [ shape = record, fontsize = 12 ] { "1" [ label = "{rl0

Re: check variable content size in sh script

2013-05-18 Thread Teske, Devin
On May 18, 2013, at 5:06 PM, Teske, Devin wrote: > > On May 18, 2013, at 4:54 PM, Quartz wrote: > >> >>> #foo works with sh >> >> Is it actually part of the official spec though is what I'm wondering, or is >> it a case of other shells not rejecting 'advanced' statements when running >> in

Re: check variable content size in sh script

2013-05-18 Thread Teske, Devin
On May 18, 2013, at 4:54 PM, Quartz wrote: > >> #foo works with sh > > Is it actually part of the official spec though is what I'm wondering, or is > it a case of other shells not rejecting 'advanced' statements when running in > emulation. > Shells don't have an "emulation mode". The shell

Re: check variable content size in sh script

2013-05-18 Thread Quartz
By default, there is no bash on FreeBSD, Right right... I know this, but forgot what list I was on :) It doesn't help that I always install bash first thing on any freebsd box or it get's installed automatically as part of pc-bsd anyway. __ it has a certai

Prevent starting network on fwe0 and fwip0

2013-05-18 Thread Martin Alejandro Paredes Sanchez
Hi: How can I prevent the start of network on fwe0 and fwip0? fwe0: Ethernet over FireWire fwip0: IP over FireWire In /etc/rc.conf I added this line network_interfaces="lo0 fxp0 wpi0" But I still see that FreeBSD start fwe0 and fwip0 Starting Network: lo0 fxp0 wpi0 Starting Network: fwe0 Star

Re: check variable content size in sh script

2013-05-18 Thread Quartz
#foo works with sh Is it actually part of the official spec though is what I'm wondering, or is it a case of other shells not rejecting 'advanced' statements when running in emulation. At least FreeBSD's implementation of sh (which is ash, I think) supports the # functionality. The rea

Re: check variable content size in sh script

2013-05-18 Thread Teske, Devin
On May 18, 2013, at 9:06 AM, Polytropon wrote: > On Sat, 18 May 2013 11:58:30 -0400, Quartz wrote: >> newfoo=${foo:0:51} >>> >>> That works for bash, not sh. >> >> Ok granted, but I don't think that ${#foo} is straight sh either, so I >> assumed "things bash/tcsh/ksh/whatever accep

Re: Hot Swapping SATA drive?

2013-05-18 Thread Quartz
Be aware that Windows up through XP doesn't support ahci, There is a huge amount of information via a quick Google search that would seem to contradict your statements regarding WinXP and AHCI. Sorry, poor choice of wording. I meant earlier versions of Windows don't support achi *natively

Re: netgraph network setup for jail(8) vnet jails.

2013-05-18 Thread Teske, Devin
Sorry for top-post, but just wanted to add a quick note: The output of "ngctl dot" would be very helpful to others in debugging your setup. -- Devin On May 18, 2013, at 8:38 AM, Joe wrote: > Hello list > > I cant get to the internet using this netgraph setup script. > I sure would appreciate

Re: Hot Swapping SATA drive?

2013-05-18 Thread Quartz
You need the sata ports running in straight up pure ahci mode (as opposed to "IDE mode" or "compatible" or something that emulates old style parallel-ata). OK. Thanks Quartz,. I'll make it a point to check for that. The wording on different bios' can often be confusing. I've seen ahci mod

Re: Hot Swapping SATA drive?

2013-05-18 Thread Ronald F. Guilmette
In message <519794e9.6080...@sneakertech.com>, Quartz wrote: >> 3) Assuming that I want to do this stuff, what BIOS options should I >> be setting or unsetting on the motherboard? > >You need the sata ports running in straight up pure ahci mode (as >opposed to "IDE mode" or "compatible" or so

Re: More than 32 CPUs under 8.4-P

2013-05-18 Thread Ivan Klymenko
В Sat, 18 May 2013 10:13:08 -0700 Dennis Glatting пишет: > > I have a 4x16=64 core server running FreeBSD 8.4-P but only two of the > CPUs (2x16=32) are enabled. Enabling the other 32 isn't as simple as > changing MAXCPU in param.h (apparently) and recompiling. > > What do I need to do to enabl

Re: More than 32 CPUs under 8.4-P

2013-05-18 Thread Dennis Glatting
On Sat, 2013-05-18 at 20:24 +0300, Ivan Klymenko wrote: > В Sat, 18 May 2013 10:13:08 -0700 > Dennis Glatting пишет: > > > > > I have a 4x16=64 core server running FreeBSD 8.4-P but only two of the > > CPUs (2x16=32) are enabled. Enabling the other 32 isn't as simple as > > changing MAXCPU in pa

Re: More than 32 CPUs under 8.4-P

2013-05-18 Thread Ivan Klymenko
В Sat, 18 May 2013 10:13:08 -0700 Dennis Glatting пишет: > > I have a 4x16=64 core server running FreeBSD 8.4-P but only two of the > CPUs (2x16=32) are enabled. Enabling the other 32 isn't as simple as > changing MAXCPU in param.h (apparently) and recompiling. Oops, sorry :) __

More than 32 CPUs under 8.4-P

2013-05-18 Thread Dennis Glatting
I have a 4x16=64 core server running FreeBSD 8.4-P but only two of the CPUs (2x16=32) are enabled. Enabling the other 32 isn't as simple as changing MAXCPU in param.h (apparently) and recompiling. What do I need to do to enable the other 32 cores? Copyright (c) 1992-2013 The FreeBSD Project. Co

Re: Hot Swapping SATA drive?

2013-05-18 Thread Jerry
On Sat, 18 May 2013 10:49:13 -0400 Quartz articulated: > You need the sata ports running in straight up pure ahci mode (as > opposed to "IDE mode" or "compatible" or something that emulates old > style parallel-ata). Be aware that Windows up through XP doesn't > support ahci, so if you're dual b

Graphics card differences between CentOS and FBSD (multi monitor)?

2013-05-18 Thread Dennis Glatting
I have a graphics card that behaves differently under CentOS 6.4 and FreeBSD 9.1. Specifically, it is an older card (Spapphire with a ATI chip set) where I have a multi-monitor set up but under CentOS the monitors come up as expected but under FreeBSD there is some kind of weird video-line overlap

Re: check variable content size in sh script

2013-05-18 Thread Polytropon
On Sat, 18 May 2013 11:58:30 -0400, Quartz wrote: > > >> newfoo=${foo:0:51} > >> > > > > That works for bash, not sh. > > Ok granted, but I don't think that ${#foo} is straight sh either, so I > assumed "things bash/tcsh/ksh/whatever accept when running in sh > emulation" were ok. By default,

Re: check variable content size in sh script

2013-05-18 Thread Tim Daneliuk
#foo works with sh On May 18, 2013 10:58:30 AM Quartz wrote: >> newfoo=${foo:0:51} >> > > That works for bash, not sh. Ok granted, but I don't think that ${#foo} is straight sh either, so I assumed "things bash/tcsh/ksh/whatever accept when running in sh emulation" were ok.

Re: check variable content size in sh script

2013-05-18 Thread Quartz
newfoo=${foo:0:51} That works for bash, not sh. Ok granted, but I don't think that ${#foo} is straight sh either, so I assumed "things bash/tcsh/ksh/whatever accept when running in sh emulation" were ok. __ it has a certain smooth-brained appeal _

netgraph network setup for jail(8) vnet jails.

2013-05-18 Thread Joe
Hello list I cant get to the internet using this netgraph setup script. I sure would appreciate giving this console log a look over for errors. My netgraph knowledge level is not sufficient to see what is wrong. The goal is to run this script to setup and break down a netgraph network for a singl

Re: check variable content size in sh script

2013-05-18 Thread Quartz
However, if the OP wanted to actually truncate $FOO to 51 characters: NEWFOO=$( echo "$FOO" | awk -v max=51 '{print substr($0,0,max)}' ) You don't need all that for a simple truncation/substring, you can do it with a direct assignment: newfoo=${foo:0:51} The three params here are "variabl

Re: check variable content size in sh script

2013-05-18 Thread Tim Daneliuk
On 05/18/2013 10:09 AM, Quartz wrote: However, if the OP wanted to actually truncate $FOO to 51 characters: NEWFOO=$( echo "$FOO" | awk -v max=51 '{print substr($0,0,max)}' ) You don't need all that for a simple truncation/substring, you can do it with a direct assignment: newfoo=${foo:0:5

Re: Hot Swapping SATA drive?

2013-05-18 Thread Quartz
1) Given a system running FreeBSD 9.1-RELEASE, is anything bad gonna happen if I insert a drive into this thing while the system is running? Assuming your board supports sata hotswap (too lazy to check) it'll be just fine. I've done this many times with the machine I'm messing with zfs on.

RE: ZFS install on a partition

2013-05-18 Thread Ivailo Tanusheff
The software RAID depends not only from the disks, but also from the changes on the OS, which will occur more frequently than an update of the firmware of the raid controller. So that makes the hardware raid more stable and reliable. Also the resources of the hardware raid are exclusively used by

Re: License on the original BSD diff

2013-05-18 Thread Clifford Yapp
On Sat, May 18, 2013 at 7:59 AM, Dag-Erling Smørgrav wrote: > Clifford Yapp writes: > > The issue is of some interest because the wiki page documenting > > candidates to replace GPL software in base list the OpenBSD copies of > > the diff tools: [...] > > We already have working BSD-licensed ver

Re: ZFS install on a partition

2013-05-18 Thread Paul Kraus
On May 18, 2013, at 12:49 AM, kpn...@pobox.com wrote: > On Fri, May 17, 2013 at 08:03:30PM -0400, Paul Kraus wrote: >> On May 17, 2013, at 6:24 PM, "b...@todoo.biz" wrote: >>> 3. Should I avoid using ZFS since my system is not well tuned and It would >>> be asking for trouble to use ZFS in these

Re: ZFS install on a partition

2013-05-18 Thread Paul Kraus
On May 18, 2013, at 3:21 AM, Ivailo Tanusheff wrote: > If you use HBA/JBOD then you will rely on the software RAID of the ZFS > system. Yes, this RAID is good, but unless you use SSD disks to boost > performance and a lot of RAM the hardware raid should be more reliable and > mush faster.

Re: Compiling a lean kernel of 9.1 p3

2013-05-18 Thread Lowell Gilbert
Tommy Pham writes: > On Wed, May 15, 2013 at 10:43 AM, Tommy Pham wrote: > >> Hi everyone, >> >> I installed 9.1 from DVD with src only and did 'freebsd-update fetch >> install'. Then I proceed to compile the lean kernel. I'm unable to >> compile a lean (no SCSI, RAID, sound, USB, Firewire, NI

Re: License on the original BSD diff

2013-05-18 Thread Dag-Erling Smørgrav
Clifford Yapp writes: > The issue is of some interest because the wiki page documenting > candidates to replace GPL software in base list the OpenBSD copies of > the diff tools: [...] We already have working BSD-licensed versions of diff and diff3 in the SoC repo. DES -- Dag-Erling Smørgrav - d

pkg version -L howto?

2013-05-18 Thread Robert Huff
Leslie Jensen writes: > pkg version -vIL > pkg: option requires an argument -- L > usage: pkg version [-IPR] [-hoqv] [-l limchar] [-L limchar] [[-X] -s string] > [-r reponame] [-O origin] [index] > pkg version -t > pkg version -T > > According to "p

pkg version -L howto?

2013-05-18 Thread Leslie Jensen
I ran into a little problem with my "old" crontab scripts. I do the following: portsnap -I cron update /usr/local/sbin/portmaster -y --clean-distfiles /usr/local/sbin/portmaster -aF pkg version -vIL After changing to pkg the check for outdated ports fails on the -L flag pkg version -vIL p

RE: ZFS install on a partition

2013-05-18 Thread Ivailo Tanusheff
Hi, If you go with RAID6 setup on your RAID I think you will not need spare so much, as you will actually have data redundancy distributed over 2 disks. I think you can use 2 or 3 LUNS, just to have more flexibility in the solution, but it is not a must :) For the usage of two copies on pool na

RE: ZFS install on a partition

2013-05-18 Thread Ivailo Tanusheff
Hi, If you use HBA/JBOD then you will rely on the software RAID of the ZFS system. Yes, this RAID is good, but unless you use SSD disks to boost performance and a lot of RAM the hardware raid should be more reliable and mush faster. I didn't get if you want to use the system to dual boot Linux/F

RE: ZFS install on a partition

2013-05-18 Thread Ivailo Tanusheff
Hi, The overhead depends of the quantity of the changes you made since the oldest snapshot and the current data on the ZFS pool. The snapshots keep only the differences between the live system and each other, so if you have made 10GB changes over the last 7 days and your oldest snapshot is 7 da