Re: some kind of binary sed(1) command

2012-02-02 Thread Matthias Apitz
El día Thursday, February 02, 2012 a las 01:51:56AM -0600, Robert Bonomi 
escribió:

  From owner-freebsd-questi...@freebsd.org  Thu Feb  2 00:27:33 2012
  Date: Thu, 2 Feb 2012 07:22:36 +0100
  From: Matthias Apitz g...@unixarea.de
  To: freebsd-questions@freebsd.org
  Subject: some kind of binary sed(1) command
 
 
  Hello,
 
  I have a normal ASCII file wich has in some places two lines of '*',
  separated by an empty line, i.e.
 
  \n
  *\n
  \n
  *\n
  \n
 
  and I want to substitute the \n between the star lines by \f; the
  'binary' sed command would just be 
 
  s/*\n\n*/*\n\f*/
 
  which ofc does not work with sed(1) because it is line oriented;
  I could write something in perl, C, awk or whatever language, but I
  would prefer to do it with the normal commands... any ideas?
 
 lightbulb mode=on
 Use sed.  
 /lightbulb
 
 *GRIN*

Thanks, but the attached script (based on your content and saved to a
script file) just gives:

$ sh sed
sed: 5:  t l
   :l
 ...: invalid command code /


Leaving your original mail as well here; Thanks again

matthias

 
 
 
 
 
 As follows:
 
   sed -e ' t l
:l
/^[*]+$/ {
N
!/\n$/ { 
P
s/^.*\n//
t l
}
/\n$/ {
N
!/\n\n[*]*$/ {
P
s/^.*\n//
P
s/^.*\n//
t l
}
/\n\n[*]*$/ s/\n\n/\n\f/
}  
}'  
 
 Note: how this incantation works is left as an excercise for the student. 
   Careful perusal of the FM will provide enlightenment.
 
 Caveat: this will convert:
{stars}
{blank}
{stars}
{blank}
{stars}
 
 to;
{stars}
{formfeed}
{stars}
{blank}
{stars}
 
 not:
{stars}
{formfeed}
{stars}
{formfeed}
{stars}
 ___
 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

-- 
Matthias Apitz
t +49-89-61308 351 - f +49-89-61308 399 - m +49-170-4527211
e g...@unixarea.de - w http://www.unixarea.de/
¡Ya basta! ¡Imperialistas occidentales, quitad las manos de Libia!
There's an end of it! Imperialists occidentals, hands off Libya!
Schluss jetzt endlich! Imperialisten des Westens, Haende weg von Libyen!
#!/bin/sh

  sed -e ' t l
   :l
   /^[*]+$/ {
   N
   !/\n$/ { 
   P
   s/^.*\n//
   t l
   }
   /\n$/ {
   N
   !/\n\n[*]*$/ {
   P
   s/^.*\n//
   P
   s/^.*\n//
   t l
   }
   /\n\n[*]*$/ s/\n\n/\n\f/
   }  
   }'  
___
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: Clang and ports

2012-02-02 Thread Matthew Seaman
On 02/02/2012 07:41, Joshua Isom wrote:
 I know that build cluster lists some ports that have problems with
 clang, but it doesn't say if they're tested or not.  I set up a clang
 jail to test out things before switching to clang for general use.  When
 I try running mencoder to encode a file to x264, it seg faults. Changing
 options doesn't change anything.  A gdb backtrace points to x264 being
 the problem.  Everything compiles and installs, but the build's
 useless.  Is clang ready for ports, or is it only safe for kernel/world?

It is certainly true that more ports will compile with the base gcc-4.2
compiler than will compile with clang.  It's also true that of the ports
that do compile, there will be more run-time failures with clang than
with gcc.

At the last test it was something like 18,000 out of 23,000 ports that
built successfully with clang -- remember though that figure (a)
includes a lot of ports that don't use a compiler at all (like shell
scripts or pure-perl code) and (b) some of the failures are because a
dependency failed to compile, which blocks testing on anything further
down the tree, or for reasons completely unrelated to the compiler, like
being unable to fetch distfiles.

See: http://wiki.freebsd.org/PortsAndClang

I personally have a FreeBSD 9-STABLE VM where everything (system+ports)
is compiled with clang, but it's just for testing, has nothing
particularly valuable on it and no one would care if it laid down and
died.  I am planning on upgrading my primary machine to 9.0 sometime
soon, and while still undecided whether to build the system with clang
or not, I certainly won't be enabling it for ports just yet.

Cheers,

Matthew

-- 
Dr Matthew J Seaman MA, D.Phil.   7 Priory Courtyard
  Flat 3
PGP: http://www.infracaninophile.co.uk/pgpkey Ramsgate
JID: matt...@infracaninophile.co.uk   Kent, CT11 9PW



signature.asc
Description: OpenPGP digital signature


HowTo easy use IPFW

2012-02-02 Thread Коньков Евгений
this is the mine script which helps me keep my firewall very clean and safe.

It is easy to understand even if you have a thousands rules, I think =)

please comment.

PS. If anybody may, please put into ports tree. thank you.


usr-local-etc-firewall.rar
Description: Binary data
___
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: some kind of binary sed(1) command

2012-02-02 Thread Robert Bonomi

 From: Matthias Apitz g...@unixarea.de

 El dia Thursday, February 02, 2012 a las 01:51:56AM -0600, Robert Bonomi 
 escribio:

 Thanks, but the attached script (based on your content and saved to a
 script file) just gives:

*sigh*  the code worked wih gnu sed.

BSD sed is a whole lot more finicky with regard to whitespace.  And, it 
appears that  I've got some bug reports to file. 

Anyway, this is tested on FBSD 7.2:
copy _exactly_, making sure there is no trailing white-space on any line.
Then substitute an actual formfeed char for the {CTL-L}.
FreeBSD sed does not recognize either '\n' or '\f' in the substitution
string -- it strips the '\' and outputs the printable character.  *sigh* 

#!/bin/sh

sed  -e '
:l
/^[*][*]*$/ N
/\n..*$/ P
/\n..*$/ {
s/^.*\n//
b l
}
/\n$/ N
/\n\n[^*][^*]*$/ {
P
s/^.*\n// 
P
s/^.*\n//
b l
}
/\n\n[*]*$/ s/\n\n/\
{CTL-L}/'

___
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: OpenMP on FreeBSD

2012-02-02 Thread Anton Shterenlikht
On Wed, Feb 01, 2012 at 04:29:59PM -0800, Dennis Glatting wrote:
 On Thu, 2012-02-02 at 00:09 +, Anton Shterenlikht wrote:
  I'm new to OpenMP. I wonder
  if there are any special considerations
  when running OpenMP on FreeBSD?
  
 
 I run OpenMP. No special consideration. Here's a chunk from my Makefile:
 
 TARG=ecc.enc ecc.dec
 
 $TARG: *.cc *.h Makefile
 g++ -Wall -fopenmp -g -O ${INCL} ${LIBS} -o ecc.enc *.cc
 g++ -Wall -fopenmp -g -O ${INCL} ${LIBS} -o ecc.dec *.cc
 
 
  For example, I have this OMP parallelised
  fortran program, nested do loops, compiled
  with gfortran46. When I run it with 2 threads
  on a 2-cpu box, I see in top(1):
  
PIDUID   PRI NICE   SIZERES STATE   C   TIMECPU COMMAND
  63995   1001890 57048K 34272K CPU11   1:06 55.08% 
  dummy.sx{dummy.sx}
  63995   1001870 57048K 34272K RUN 1   1:02 52.39% 
  dummy.sx{dummy.sx}
 11  0   155 ki31 0K32K RUN 0 376:58 51.46% idle{idle: 
  cpu0}
 11  0   155 ki31 0K32K RUN 1 368:18 45.36% idle{idle: 
  cpu1}
  
  I wonder why, even after a minute of run time,
  I still have nearly a whole cpu idle?
  
 
 What is the program doing? I/O can significantly limit OMP value. Also,
 you need to make sure you code your loops properly or else you have a
 single-threaded application, without warning.

Here's my parallel bit:

!$OMP PARALLEL DEFAULT(NONE) 
!$OMP   SHARED(AEND,SPACE1,SPACE2,SIZE1,SIZE2,SIZE3) 
!$OMP   PRIVATE(STEP,RANDN,X1,X2,X3)

!$OMP DO SCHEDULE(RUNTIME)

   DO X3 = 1,SIZE3
 DO X2 = 1,SIZE2
   DO X1 = 1,SIZE1

 IF(SPACE1(X1,X2,X3).EQ.0) THEN
   AEND = .FALSE.! UPDATE AT LEAST ONE CELL
   CALL RANDOM_NUMBER(RANDN) ! 0 = RANDN  1
   STEP = NINT(RANDN*2-1)! STEP = [-1 0 1]
   SPACE2(X1,X2,X3) = SPACE1(X1+STEP(1),X2+STEP(2),X3+STEP(3))
 END IF
 
   END DO
 END DO
   END DO

!$OMP END DO
!$OMP END PARALLEL

There's no I/O at all. Not sure what you mean
by proper looping. The threads are definitely
created. I use setenv OMP_NUM_THREADS to set
the number of threads. Then I monitor thread
creation with top -H. The number of threads
shown there matches what I set. So I'm pretty
sure the executable is multi-threaded.

Perhaps I should explore various SCHEDULE options?

By the way, what sort of speed-up do you
see with your loop? And what ratio threads/cores
is optimal for you?

Many thanks

-- 
Anton Shterenlikht
Room 2.6, Queen's Building
Mech Eng Dept
Bristol University
University Walk, Bristol BS8 1TR, UK
Tel: +44 (0)117 331 5944
Fax: +44 (0)117 929 4423
___
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


help needed for connecting internet with ZTE ac 8700 USB cdma ( EvDO) modem

2012-02-02 Thread Subhasish Chakraborty
I am new to Free bsd and installed PC-BSD 9 recently in my desktop. Its a
dual boot with windows 7 and I use ZTE ac8700 to connect to internet. From
windows the Usb stick is working fine ahe driver for windows need phone no
#777 , username and password to connect . I tested the device and its
working fine in Linux too . But in PC-BSD neither  the default gui is
working nor the CLI is clicking. A wvdial port might have helped as in
linux it worked like charm with real easy configuration. I have some
duckduckgo-ing and tryed to edit a few configuration on my own as gui is
not helping .

In my my PC-BSD /etc/ppp/ppp.conf file looks like .


default:

set log Phase Chat LCP IPCP CCP tun command
ident user-ppp VERSION (built COMPILATIONDATE)

set device /dev/cuaU0.0

set speed 115200

set dial ABORT BUSY ABORT NO\\sCARRIER TIMEOUT 5 \
\\ AT OK-AT-OK ATE1Q0 OK \\dATDT\\T TIMEOUT 40 CONNECT
set timeout 180 # 3 minute idle timer (the default)

enable dns # request DNS info (for resolv.conf)




isp:

set phone #777

set authname Username

set authkey pass

set dns 208.67.220.220 208.67.222.222 # openDNS

#set ifaddr 10.1.0.2/0 10.1.0.1/0 255.255.255.255 0.0.0.0

# add default HISADDR
enable dns




Now ppp -ddial isp gives me



kernel: tun0: link state changed to UP

ppp[18473]: tun0: Warning: Chat script failed

in /var/log/messages ..

can someone please put some light on whats wrong in here or please help me
to write a ppp.config

Here's the output of my pc configuration ..

usbconfig

ugen0.1: OHCI root HUB ATI at usbus0, cfg=0 md=HOST spd=FULL (12Mbps)
pwr=SAVE
ugen1.1: OHCI root HUB ATI at usbus1, cfg=0 md=HOST spd=FULL (12Mbps)
pwr=SAVE
ugen2.1: OHCI root HUB ATI at usbus2, cfg=0 md=HOST spd=FULL (12Mbps)
pwr=SAVE
ugen3.1: OHCI root HUB ATI at usbus3, cfg=0 md=HOST spd=FULL (12Mbps)
pwr=SAVE
ugen4.1: OHCI root HUB ATI at usbus4, cfg=0 md=HOST spd=FULL (12Mbps)
pwr=SAVE
ugen5.1: EHCI root HUB ATI at usbus5, cfg=0 md=HOST spd=HIGH (480Mbps)
pwr=SAVE
ugen0.2: product 0x08da vendor 0x046d at usbus0, cfg=0 md=HOST spd=FULL
(12Mbps) pwr=ON
ugen0.3: ZTE CDMA Tech ZTE, Incorporated at usbus0, cfg=0 md=HOST
spd=FULL (12Mbps) pwr=ON


sysctl -a dev.u3g

dev.u3g.0.%desc: Data Interface
dev.u3g.0.%driver: u3g
dev.u3g.0.%location: bus=1 hubaddr=2 port=0 devaddr=3 interface=0
dev.u3g.0.%pnpinfo: vendor=0x19d2 product=0xfffe devclass=0x00
devsubclass=0x00 sernum= release=0x mode=host intclass=0xff
intsubclass=0xff intprotocol=0xff ttyname=U0 ttyports=4
dev.u3g.0.%parent: uhub0


ls -l /dev/cuaU*

crw-rw 1 uucp dialer 0, 153 Feb 2 13:39 /dev/cuaU0.0
crw-rw 1 uucp dialer 0, 154 Feb 2 13:30 /dev/cuaU0.0.init
crw-rw 1 uucp dialer 0, 155 Feb 2 13:30 /dev/cuaU0.0.lock
crw-rw 1 uucp dialer 0, 159 Feb 2 13:30 /dev/cuaU0.1
crw-rw 1 uucp dialer 0, 160 Feb 2 13:30 /dev/cuaU0.1.init
crw-rw 1 uucp dialer 0, 161 Feb 2 13:30 /dev/cuaU0.1.lock
crw-rw 1 uucp dialer 0, 165 Feb 2 13:30 /dev/cuaU0.2
crw-rw 1 uucp dialer 0, 166 Feb 2 13:30 /dev/cuaU0.2.init
crw-rw 1 uucp dialer 0, 167 Feb 2 13:30 /dev/cuaU0.2.lock
crw-rw 1 uucp dialer 0, 171 Feb 2 13:30 /dev/cuaU0.3
crw-rw 1 uucp dialer 0, 172 Feb 2 13:30 /dev/cuaU0.3.init
crw-rw 1 uucp dialer 0, 173 Feb 2 13:30 /dev/cuaU0.3.lock
..
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


Re: carp+devd+ifstated on master problem

2012-02-02 Thread peter knezel
Hello Damien,

of course, the tnewpass was my copy error - newpass is OK and is in
config files  everywhere.
And the carp interfaces' advskew, vhid and
pass are already in /etc/rc.conf.local.

What I simply would like to try is run scripts if carp interfaces change.
Actually my real aim is to synchronize file from slave server to
master if master reboots or slave becomes master due to carp problems
on the master.
Regards,
Peter


On 01/02/2012, Damien Fleuriot m...@my.gd wrote:


 On 2/1/12 12:12 PM, peter knezel wrote:
 Hello all,

 I have configured devd and ifstated on a master FreeBSD server (slave
 not changed so far) on which carp was configured with three
 carp0,carp1 and carp2 virtual addresses.

 When I as root do ifconfig carp0 down and up, the corresponding
 testdown.sh and testup.sh
 scripts are run (defined in ifstated.conf).
 The status of carp0 interface changes to INIT then to MASTER (after
 ifconfig carp0 up).

 However this is not valid when doing the same with carp1 or carp2.
 It goes to INIT+testdown.sh executed but then immediately afterwards
 it goes to MASTER+testup.sh executed.

 What can be the problem?

 cd /usr/local/etc
 cat ifstated.conf
 init-state one

 net = '( ifconfig -a -u |grep carp0  /dev/null every 3  ifconfig -a
 -u
 |grep carp1  /dev/null every 3  ifconfig -a -u |grep carp2 
 /dev/null
 every 3)'

 state one {
 if ( ! $net ) {
 run /sbin/ifconfig_carp0 vhid 1 pass newpass
 192.xx.xx.1/24
 run /sbin/ifconfig carp1 vhid 2 pass newpass
 192.xx.xx.2/24
 run /sbin/ifconfig carp2 vhid 3 pass newpass
 192.xx.xx.3/24
 run /usr/local/testdown.sh
 set-state two
 }
 }

 state two {
 if ( $net ) {
 run /sbin/ifconfig carp0 vhid 1 advskew 100 pass
 tnewpass 192.xx.xx.1/24
 run /sbin/ifconfig carp1 vhid 2 advskew 100 pass
 newpass 192.xx.xx.2/24
 run /sbin/ifconfig carp2 vhid 3 advskew 100 pass
 newpass 192.xx.xx.3/24
 run /usr/local/testup.sh
 set-state one
 }
 }

 In addition I had to configure devd.conf to have ifdown.sh and ifup.sh
 scripts executed when reboot is done on the master.

 notify 30 {
 match system IFNET;
 match subsystem carp0;
 match type LINK_UP;
 action /usr/local/etc/rc.d/ifdown.sh;
 };

 notify 30 {
 match system IFNET;
 match subsystem carp0;
 match type LINK_DOWN;
 action /usr/local/etc/rc.d/ifup.sh;

 Thanks for any suggestion in advance.

 Ardi

 I'm not sure I get what you're trying to do here.

 Is there a reason you do not set your carp interfaces' advskew, vhid and
 pass in /etc/rc.conf ?

 Also, I notice in state 2 your password for carp0 is tnewpass, while the
 other ones are newpass.

 ___
 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: some kind of binary sed(1) command

2012-02-02 Thread Nikos Vassiliadis

On 2/2/2012 8:22 AM, Matthias Apitz wrote:


Hello,

I have a normal ASCII file wich has in some places two lines of '*',
separated by an empty line, i.e.

\n
*\n
\n
*\n
\n

and I want to substitute the \n between the star lines by \f; the
'binary' sed command would just be

s/*\n\n*/*\n\f*/

which ofc does not work with sed(1) because it is line oriented;
I could write something in perl, C, awk or whatever language, but I
would prefer to do it with the normal commands... any ideas?

Thanks

matthias


Perhaps, something like this:

raidmadi% sed '/\*\*\*\*/{ N;N;s/\(\*\*\*\*\n\)\(\n\)\(\*\*\*\*\)/\1\\f\
\3/; }; '




\f


foo


foo



Keep in mind that I am using zsh which allows you to write multi-line
commands.

HTH, Nikos
___
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: carp+devd+ifstated on master problem

2012-02-02 Thread Damien Fleuriot
We're using ifstated to send nagios passive alerts in case a lagg or
carp's interface's state should become degraded.

Find below the config we're using:








carp_up = carp410.link.up  carp13.link.up
carp_down = carp410.link.down  carp13.link.down
carp_unknown = carp410.link.unknown || carp13.link.unknown
init-state auto

state auto {
set-state inconnu
if $carp_up {
set-state primary
}
if $carp_down {
set-state backup
}
if $carp_unknown {
set-state inconnu
}
}

state primary {
init {
run echo \pf1-gs.hipay;carp;0;carp Master\| send_nsca_2.7 -H
monit1.hipay.eqx -d \;\ -c /usr/local/etc/send_nsca.cfg
run echo \pf1-gs.hipay;carp;0;carp Master\| send_nsca_2.7 -H
monit1.hipay -d \;\ -c /usr/local/etc/send_nsca.cfg
}
if $carp_down {
set-state backup
}
if $carp_unknown {
set-state inconnu
}
if bce0.link.up  bce1.link.up {
run echo \pf1-gs.hipay;bond;0;BONDING OK\|
send_nsca_2.7 -H monit1.hipay.eqx -d \;\ -c /usr/local/etc/send_nsca.cfg
run echo \pf1-gs.hipay;bond;0;BONDING OK\| send_nsca_2.7 -H
monit1.hipay -d \;\ -c /usr/local/etc/send_nsca.cfg
}
if bce0.link.down || bce1.link.down {
run echo \pf1-gs.hipay;bond;2;BONDING DEGRADED\|
send_nsca_2.7 -H monit1.hipay.eqx -d \;\ -c /usr/local/etc/send_nsca.cfg
run echo \pf1-gs.hipay;bond;2;BONDING DEGRADED\| 
send_nsca_2.7 -H
monit1.hipay -d \;\ -c /usr/local/etc/send_nsca.cfg
}
}


state backup {
init {
run echo \pf1-gs.hipay;carp;2;carp Backup\| send_nsca_2.7 -H
monit1.hipay.eqx -d \;\ -c /usr/local/etc/send_nsca.cfg
run echo \pf1-gs.hipay;carp;2;carp Backup\| send_nsca_2.7 -H
monit1.hipay -d \;\ -c /usr/local/etc/send_nsca.cfg
}
if $carp_up {
set-state primary
}
if $carp_unknown {
set-state inconnu
}
if bce0.link.up  bce1.link.up {
run echo \pf1-gs.hipay;bond;0;BONDING OK\| send_nsca_2.7 -H
monit1.hipay.eqx -d \;\ -c /usr/local/etc/send_nsca.cfg
run echo \pf1-gs.hipay;bond;0;BONDING OK\| send_nsca_2.7 -H
monit1.hipay -d \;\ -c /usr/local/etc/send_nsca.cfg
}
if bce0.link.down || bce1.link.down {
run echo \pf1-gs.hipay;bond;2;BONDING DEGRADED\| 
send_nsca_2.7 -H
monit1.hipay.eqx -d \;\ -c /usr/local/etc/send_nsca.cfg
run echo \pf1-gs.hipay;bond;2;BONDING DEGRADED\| 
send_nsca_2.7 -H
monit1.hipay -d \;\ -c /usr/local/etc/send_nsca.cfg
}

}

state inconnu {
init {
run echo \pf1-gs.hipay;carp;2;carp INIT\| send_nsca_2.7 -H
monit1.hipay.eqx -d \;\ -c /usr/local/etc/send_nsca.cfg
run echo \pf1-gs.hipay;carp;2;carp INIT\| send_nsca_2.7 -H
monit1.hipay -d \;\ -c /usr/local/etc/send_nsca.cfg
}
if $carp_up {
set-state primary
}
if $carp_down {
set-state backup
}
if bce0.link.up  bce1.link.up {
run echo \pf1-gs.hipay;bond;0;BONDING OK\|
send_nsca_2.7 -H monit1.hipay.eqx -d \;\ -c /usr/local/etc/send_nsca.cfg
run echo \pf1-gs.hipay;bond;0;BONDING OK\| send_nsca_2.7 -H
monit1.hipay -d \;\ -c /usr/local/etc/send_nsca.cfg
}
if bce0.link.down || bce1.link.down {
run echo \pf1-gs.hipay;bond;2;BONDING DEGRADED\|
send_nsca_2.7 -H monit1.hipay.eqx -d \;\ -c /usr/local/etc/send_nsca.cfg
run echo \pf1-gs.hipay;bond;2;BONDING DEGRADED\| 
send_nsca_2.7 -H
monit1.hipay -d \;\ -c /usr/local/etc/send_nsca.cfg
}
}















On 2/2/12 11:25 AM, peter knezel wrote:
 Hello Damien,
 
 of course, the tnewpass was my copy error - newpass is OK and is in
 config files  everywhere.
 And the carp interfaces' advskew, vhid and
 pass are already in /etc/rc.conf.local.
 
 What I simply would like to try is run scripts if carp interfaces change.
 Actually my real aim is to synchronize file from slave server to
 master if master reboots or slave becomes master due to carp problems
 on the master.
 Regards,
 Peter
 
 
 On 01/02/2012, Damien Fleuriot m...@my.gd wrote:


 On 2/1/12 12:12 PM, peter knezel wrote:
 Hello all,

 I have configured devd and ifstated on a master FreeBSD server (slave
 not changed so far) on which carp was configured with three
 carp0,carp1 and carp2 virtual addresses.

 When I as root do ifconfig carp0 down and up, the corresponding
 testdown.sh and testup.sh
 scripts are run (defined in ifstated.conf).
 The status of carp0 interface changes to INIT then to MASTER (after
 ifconfig carp0 up).

 However this is not valid when doing the same with carp1 or carp2.
 It goes to INIT+testdown.sh executed but then immediately afterwards
 it goes to MASTER+testup.sh 

Re: carp+devd+ifstated on master problem

2012-02-02 Thread peter knezel
I have looked a bit into the ifstated.conf file and realized, that it
does not behave as I want.

So currently the setting is the following:

 cat /usr/local/etc/ifstated.conf
init-state one

net = '( ifconfig -a -u |grep carp0  /dev/null every 3  ifconfig -a -u
|grep carp1  /dev/null every 3  ifconfig -a -u |grep carp2  /dev/null
every 3)'

state one {
if ( ! $net ) {
run /sbin/ifconfig_carp0 vhid 1 pass newpass 192.xx.xx.1/24
run /sbin/ifconfig carp1 vhid 2 pass newpass 192.xx.xx.2/24
run /sbin/ifconfig carp2 vhid 3 pass newpass 192.xx.xx.3/24
run /usr/local/testup.sh
set-state two
}
}

state two {
if ( $net ) {
run /usr/local/testup.sh
set-state one
}
}


When I do ifconfig carp0 down/up script run testdown.sh/testup.sh
but not valid for carp1,carp2. It immediately brings up carp1/carp2
and runs testup.sh after executing testdown.sh if triggered with
ifconfig carp1 down (or ifconfig carp2 down).

Peter

On 02/02/2012, peter knezel peter.kne...@gmail.com wrote:
 Hello Damien,

 of course, the tnewpass was my copy error - newpass is OK and is in
 config files  everywhere.
 And the carp interfaces' advskew, vhid and
 pass are already in /etc/rc.conf.local.

 What I simply would like to try is run scripts if carp interfaces change.
 Actually my real aim is to synchronize file from slave server to
 master if master reboots or slave becomes master due to carp problems
 on the master.
 Regards,
 Peter


 On 01/02/2012, Damien Fleuriot m...@my.gd wrote:


 On 2/1/12 12:12 PM, peter knezel wrote:
 Hello all,

 I have configured devd and ifstated on a master FreeBSD server (slave
 not changed so far) on which carp was configured with three
 carp0,carp1 and carp2 virtual addresses.

 When I as root do ifconfig carp0 down and up, the corresponding
 testdown.sh and testup.sh
 scripts are run (defined in ifstated.conf).
 The status of carp0 interface changes to INIT then to MASTER (after
 ifconfig carp0 up).

 However this is not valid when doing the same with carp1 or carp2.
 It goes to INIT+testdown.sh executed but then immediately afterwards
 it goes to MASTER+testup.sh executed.

 What can be the problem?

 cd /usr/local/etc
 cat ifstated.conf
 init-state one

 net = '( ifconfig -a -u |grep carp0  /dev/null every 3  ifconfig
 -a
 -u
 |grep carp1  /dev/null every 3  ifconfig -a -u |grep carp2 
 /dev/null
 every 3)'

 state one {
 if ( ! $net ) {
 run /sbin/ifconfig_carp0 vhid 1 pass newpass
 192.xx.xx.1/24
 run /sbin/ifconfig carp1 vhid 2 pass newpass
 192.xx.xx.2/24
 run /sbin/ifconfig carp2 vhid 3 pass newpass
 192.xx.xx.3/24
 run /usr/local/testdown.sh
 set-state two
 }
 }

 state two {
 if ( $net ) {
 run /sbin/ifconfig carp0 vhid 1 advskew 100 pass
 tnewpass 192.xx.xx.1/24
 run /sbin/ifconfig carp1 vhid 2 advskew 100 pass
 newpass 192.xx.xx.2/24
 run /sbin/ifconfig carp2 vhid 3 advskew 100 pass
 newpass 192.xx.xx.3/24
 run /usr/local/testup.sh
 set-state one
 }
 }

 In addition I had to configure devd.conf to have ifdown.sh and ifup.sh
 scripts executed when reboot is done on the master.

 notify 30 {
 match system IFNET;
 match subsystem carp0;
 match type LINK_UP;
 action /usr/local/etc/rc.d/ifdown.sh;
 };

 notify 30 {
 match system IFNET;
 match subsystem carp0;
 match type LINK_DOWN;
 action /usr/local/etc/rc.d/ifup.sh;

 Thanks for any suggestion in advance.

 Ardi

 I'm not sure I get what you're trying to do here.

 Is there a reason you do not set your carp interfaces' advskew, vhid and
 pass in /etc/rc.conf ?

 Also, I notice in state 2 your password for carp0 is tnewpass, while the
 other ones are newpass.

 ___
 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: Unable to upgrade packages on FreeBSD

2012-02-02 Thread Bernt Hansson

2012-02-01 19:16, David Jackson skrev:


I did not save them, there is really no way to save a copy of them unless I
copy them by hand.


I take it you are new to FreeBSD. May I introduce you to script
man script(1)
___
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: Unable to upgrade packages on FreeBSD

2012-02-02 Thread Waitman Gobble
On Thu, Feb 2, 2012 at 5:18 AM, Bernt Hansson b...@bananmonarki.se wrote:

 2012-02-01 19:16, David Jackson skrev:


  I did not save them, there is really no way to save a copy of them unless
 I
 copy them by hand.


 I take it you are new to FreeBSD. May I introduce you to script
 man script(1)

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



One thing I noticed, which may cause some trouble(?)

http://ftp.freebsd.org/pub/FreeBSD/ports/i386/packages-10-current/ is
empty, no packages. So pkg_add fails for everything...

Running 10-CURRENT I have to set PACKAGESITE
to http://ftp.freebsd.org/pub/FreeBSD/ports/i386/packages-current/Latest/

It's been years since I've run a HEAD version of FreeBSD - maybe this is
common knowledge. :)
But It seems like there could be a symlink or something.

Also, I'm still looking into it - but it seems like it would be good to
have an easy way to 'reinstall' a package.
It seems to be pretty stubborn when trying to deinstall/reinstall stuff.
For example, after i upgraded from
9.0-RELEASE to 10-CURRENT, the thing was complaining about libintl,
gettext, iconv.
pkg_add was refusing to 'reinstall' (but this might be related my own
ignorance), so I ended up
going into ports and building, then the system was fulling operational, yay.

However, it could be that these did not need to be reinstalled. pkg_add
was telling me I already had the
latest versions installed, and when I finally got down to the meat of my
problem I found that my /etc/rc was never replaced.
Either I fat-fingered a mergemaster prompt (but I really thought I was
paying close attention), or mergemaster missed it! :)
There was no /var/tmp/temproot/etc/rc after mergemaster, and mergemaster
reported that only two files were left to do
by hand, which is what I had intended. (ie, groups, master.passwd) But
doing a diff between /usr/src/etc/rc (i think) and /etc/rc I
saw they were different,  copied the file and 10-CURRENT ran perfectly.



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: HowTo easy use IPFW

2012-02-02 Thread Jason Hellenthal

You are welcome to create a port and submit it for reccomendation...

For that you should review the documents etc... at
http://freebsd.org/docs

Good Luck

On Thu, Feb 02, 2012 at 11:33:14AM +0200, Коньков Евгений wrote:
 this is the mine script which helps me keep my firewall very clean and safe.
 
 It is easy to understand even if you have a thousands rules, I think =)
 
 please comment.
 
 PS. If anybody may, please put into ports tree. thank you.


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


-- 
;s =;
___
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: HowTo easy use IPFW

2012-02-02 Thread Jerry
On Thu, 2 Feb 2012 12:10:14 -0500
Jason Hellenthal articulated:

 For that you should review the documents etc... at
 http://freebsd.org/docs

Which will get you a big: 404 - Not Found

You could start here though:

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

-- 
Jerry ♔

Disclaimer: off-list followups get on-list replies or get ignored.
Please do not ignore the Reply-To header.
__

___
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


Asymmetric NFS Performance

2012-02-02 Thread Tim Daneliuk

Server:FBSD 8.2-STABLE / MTU set to 15000
Client:Linux Mint 12   / MTU set to 8192
NFS Mount Options: rw,soft,intr
Problem:

Throughput copying from Server to Client is about 2x that when
copying a file from client to server.  The client does have
a SSD whereas the server has conventional SATA drives but ...
This problem is evident with either 100- or 1000- speed ethernet
so I don't think it is a drive thing since you'd expect to saturate
100-BASE with either type of drive.

Things I've Tried So Far:

- Increasing the MTUs - This helped speed things up, but the up/down
  ratio stayed about the same.

- Fiddling with rsize and wsize on the client - No real difference


Ideas anyone?







---
Tim Daneliuk
___
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: uname ?

2012-02-02 Thread Chad Perrin
On Thu, Feb 02, 2012 at 03:09:00PM +0800, joeb1 wrote:
 It looks to me that the  uname -m  and  uname -p  always have the same
 value, such as i386.
 
 Is there some fine-grained difference or some un-documented difference
 between them
 or some combination were the values would be different?

I don't have one handy, so I don't have any way to test this right now,
but I wonder if an AMD machine might give a different answer to one of
those than an Intel machine, given a 32-bit 386 instruction set processor
for both.

-- 
Chad Perrin [ original content licensed OWL: http://owl.apotheon.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: uname ?

2012-02-02 Thread Yuri Pankov
On Thu, Feb 02, 2012 at 11:30:51AM -0700, Chad Perrin wrote:
 On Thu, Feb 02, 2012 at 03:09:00PM +0800, joeb1 wrote:
  It looks to me that the  uname -m  and  uname -p  always have the same
  value, such as i386.
  
  Is there some fine-grained difference or some un-documented difference
  between them
  or some combination were the values would be different?
 
 I don't have one handy, so I don't have any way to test this right now,
 but I wonder if an AMD machine might give a different answer to one of
 those than an Intel machine, given a 32-bit 386 instruction set processor
 for both.

I *guess* they will be different for some targets in this list:

$ make targets -C /usr/src
Supported TARGET/TARGET_ARCH pairs for world and kernel targets
amd64/amd64
arm/arm
arm/armeb
i386/i386
ia64/ia64
mips/mipsel
mips/mipseb
mips/mips64el
mips/mips64eb
mips/mipsn32eb
pc98/i386
powerpc/powerpc
powerpc/powerpc64
sparc64/sparc64


Yuri


pgp3oTUsEpBMa.pgp
Description: PGP signature


Re: Unable to upgrade packages on FreeBSD

2012-02-02 Thread Eduardo Morras

At 19:16 01/02/2012, David Jackson wrote:



They seem to have failed because they couldn't find the package on the
download site. Other errors I got were that the package it had downloaded
had an unrecognized format.

I did not save them, there is really no way to save a copy of them unless I
copy them by hand. I will have to rerun the commands to get the error
messages and then transfer them by hand.


In my first mail i didn't think about this, but:

In your OP you don't say the version of FreeBSD you're running. Show 
a uname -a please. Is it a RELEASE, like 8.2-RELEASEpx? If it's a 
RELEASE perhaps you don't know that the packages are frozen but all 
are known to work  without problems. Switch to -STABLE if you want 
access newer packages but perhaps there will be problems with them 
from time to time. Check -stable maillist.


HTH 



___
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 9 buildworld with clang failure

2012-02-02 Thread Dean E. Weimer
I am trying to rebuild everything in a development machine with clang 
to test for production, and ran into a problem on the buildworld 
process.  This machine was already rebuilt from source using gcc, here 
are the options I have set in make.conf and src.conf.  The lines I added 
to enable clang, and the steps I took to compile.


Options in /etc/src.conf
WITHOUT_BIND_DNSSEC=YES
WITHOUT_BIND_LIBS_LWRES=YES
WITHOUT_BIND_NAMED=YES
WITHOUT_BIND_UTILS=YES
WITHOUT_NTP=YES
WITHOUT_PROFILE=YES

Options already in /etc/make.conf
WITH_OPENSSL_PORT=yes
WITHOUT_X11=yes
CFLAGS= -O -pipe
PERL_VERSION=5.12.4

Added to /etc/make.conf
.if !defined(USE_GCC)
.if !defined(CC) || ${CC} == cc
CC=clang
.endif
.if !defined(CXX) || ${CXX} == c++
CXX=clang++
.endif
.if !defined(CPP) || ${CPP} == cpp
CPP=clang-cpp
.endif
.endif


Did the cleanup process from previous build and currently installed 
setup.

chflags -R noschg /usr/obj/usr
rm -rf /usr/obj/usr
cd /usr/src
make cleandir
make cleandir

Then ran make buildworld, it died on libc with the following output:

=== lib/libc (obj,depend,all,install)
clang -O -pipe  -I/usr/src/lib/libc/include 
-I/usr/src/lib/libc/../../include -I/usr/src/lib/libc/amd64 -DNLS  
-D__DBINTERFACE_PRIVATE -I/usr/src/lib/libc/../../contrib/gdtoa -DINET6 
-I/usr/obj/usr/src/lib/libc -I/usr/src/lib/libc/resolv -D_ACL_PRIVATE 
-DPOSIX_MISTAKE -I/usr/src/lib/libc/../../contrib/tzcode/stdtime 
-I/usr/src/lib/libc/stdtime -I/usr/src/lib/libc/locale -DBROKEN_DES 
-DPORTMAP -DDES_BUILTIN -I/usr/src/lib/libc/rpc -DYP -DNS_CACHING 
-DSYMBOL_VERSIONING -std=gnu99 -fstack-protector -Wsystem-headers 
-Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c 
/usr/src/lib/libc/gen/setjmperr.c

In file included from /usr/src/lib/libc/gen/setjmperr.c:44:
/usr/src/lib/libc/../../include/setjmp.h:58:5: error: incompatible 
redeclaration of library function

  'sigsetjmp' [-Werror]
int sigsetjmp(sigjmp_buf, int);
^
/usr/src/lib/libc/../../include/setjmp.h:58:5: note: 'sigsetjmp' is a 
builtin with type

  'int (struct _jmp_buf *, int)'
1 error generated.
*** Error code 1

Stop in /usr/src/lib/libc.
*** Error code 1

Anyone have any idea where I went wrong?

--
Thanks,
 Dean E. Weimer
 http://www.dweimer.net/
___
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: OpenMP on FreeBSD

2012-02-02 Thread Dennis Glatting



On Thu, 2 Feb 2012, Anton Shterenlikht wrote:


On Wed, Feb 01, 2012 at 04:29:59PM -0800, Dennis Glatting wrote:

On Thu, 2012-02-02 at 00:09 +, Anton Shterenlikht wrote:

I'm new to OpenMP. I wonder
if there are any special considerations
when running OpenMP on FreeBSD?



I run OpenMP. No special consideration. Here's a chunk from my Makefile:

TARG=ecc.enc ecc.dec

$TARG: *.cc *.h Makefile
g++ -Wall -fopenmp -g -O ${INCL} ${LIBS} -o ecc.enc *.cc
g++ -Wall -fopenmp -g -O ${INCL} ${LIBS} -o ecc.dec *.cc



For example, I have this OMP parallelised
fortran program, nested do loops, compiled
with gfortran46. When I run it with 2 threads
on a 2-cpu box, I see in top(1):

  PIDUID   PRI NICE   SIZERES STATE   C   TIMECPU COMMAND
63995   1001890 57048K 34272K CPU11   1:06 55.08% dummy.sx{dummy.sx}
63995   1001870 57048K 34272K RUN 1   1:02 52.39% dummy.sx{dummy.sx}
   11  0   155 ki31 0K32K RUN 0 376:58 51.46% idle{idle: cpu0}
   11  0   155 ki31 0K32K RUN 1 368:18 45.36% idle{idle: cpu1}

I wonder why, even after a minute of run time,
I still have nearly a whole cpu idle?



What is the program doing? I/O can significantly limit OMP value. Also,
you need to make sure you code your loops properly or else you have a
single-threaded application, without warning.


Here's my parallel bit:

!$OMP PARALLEL DEFAULT(NONE) 
!$OMP   SHARED(AEND,SPACE1,SPACE2,SIZE1,SIZE2,SIZE3) 
!$OMP   PRIVATE(STEP,RANDN,X1,X2,X3)

!$OMP DO SCHEDULE(RUNTIME)

  DO X3 = 1,SIZE3
DO X2 = 1,SIZE2
  DO X1 = 1,SIZE1

IF(SPACE1(X1,X2,X3).EQ.0) THEN
  AEND = .FALSE.! UPDATE AT LEAST ONE CELL
  CALL RANDOM_NUMBER(RANDN) ! 0 = RANDN  1
  STEP = NINT(RANDN*2-1)! STEP = [-1 0 1]
  SPACE2(X1,X2,X3) = SPACE1(X1+STEP(1),X2+STEP(2),X3+STEP(3))
END IF

  END DO
END DO
  END DO

!$OMP END DO
!$OMP END PARALLEL

There's no I/O at all. Not sure what you mean
by proper looping. The threads are definitely
created. I use setenv OMP_NUM_THREADS to set
the number of threads. Then I monitor thread
creation with top -H. The number of threads
shown there matches what I set. So I'm pretty
sure the executable is multi-threaded.



The issue I found in C++ is a barrier had to be defined, which is the 
first tagged bracket in my code snippet. Without that barrier the pragma 
on the for loop was single threaded. Can't say about Fortran, sorry.


I haven't coded Fortran since collage and can't comment on your code.



Perhaps I should explore various SCHEDULE options?



Nope. When it works you will notice. Under FreeBSD I do a top -P in a 
second window. You will see the cores get busy.




By the way, what sort of speed-up do you
see with your loop? And what ratio threads/cores
is optimal for you?



A forty five minute task down to seven minutes on an eight core, AMD 8150 
processor running at 4GHz (slightly over clocked). The effort would take 
less time if I recoded using a custom thread/code solution but I'm talking 
about maybe another minute or two. In the end I felt better was the enemy 
of good.





Many thanks

--
Anton Shterenlikht
Room 2.6, Queen's Building
Mech Eng Dept
Bristol University
University Walk, Bristol BS8 1TR, UK
Tel: +44 (0)117 331 5944
Fax: +44 (0)117 929 4423


___
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: FreeBSD 9 buildworld with clang failure

2012-02-02 Thread ill...@gmail.com
On 2 February 2012 14:43, Dean E. Weimer dwei...@dweimer.net wrote:
 I am trying to rebuild everything in a development machine with clang to
 test for production, and ran into a problem on the buildworld process.  This
 machine was already rebuilt from source using gcc, here are the options I
 have set in make.conf and src.conf.  The lines I added to enable clang, and
 the steps I took to compile.

 Options in /etc/src.conf
 WITHOUT_BIND_DNSSEC=YES
 WITHOUT_BIND_LIBS_LWRES=YES
 WITHOUT_BIND_NAMED=YES
 WITHOUT_BIND_UTILS=YES
 WITHOUT_NTP=YES
 WITHOUT_PROFILE=YES

 Options already in /etc/make.conf
 WITH_OPENSSL_PORT=yes
 WITHOUT_X11=yes
 CFLAGS= -O -pipe
 PERL_VERSION=5.12.4

 Added to /etc/make.conf
 .if !defined(USE_GCC)
 .if !defined(CC) || ${CC} == cc
 CC=clang
 .endif
 .if !defined(CXX) || ${CXX} == c++
 CXX=clang++
 .endif
 .if !defined(CPP) || ${CPP} == cpp
 CPP=clang-cpp
 .endif
 .endif


 Did the cleanup process from previous build and currently installed setup.
 chflags -R noschg /usr/obj/usr
 rm -rf /usr/obj/usr
 cd /usr/src
 make cleandir
 make cleandir

 Then ran make buildworld, it died on libc with the following output:

 === lib/libc (obj,depend,all,install)
 clang -O -pipe  -I/usr/src/lib/libc/include
 -I/usr/src/lib/libc/../../include -I/usr/src/lib/libc/amd64 -DNLS
  -D__DBINTERFACE_PRIVATE -I/usr/src/lib/libc/../../contrib/gdtoa -DINET6
 -I/usr/obj/usr/src/lib/libc -I/usr/src/lib/libc/resolv -D_ACL_PRIVATE
 -DPOSIX_MISTAKE -I/usr/src/lib/libc/../../contrib/tzcode/stdtime
 -I/usr/src/lib/libc/stdtime -I/usr/src/lib/libc/locale -DBROKEN_DES
 -DPORTMAP -DDES_BUILTIN -I/usr/src/lib/libc/rpc -DYP -DNS_CACHING
 -DSYMBOL_VERSIONING -std=gnu99 -fstack-protector -Wsystem-headers -Werror
 -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c
 /usr/src/lib/libc/gen/setjmperr.c
 In file included from /usr/src/lib/libc/gen/setjmperr.c:44:
 /usr/src/lib/libc/../../include/setjmp.h:58:5: error: incompatible
 redeclaration of library function
      'sigsetjmp' [-Werror]
 int     sigsetjmp(sigjmp_buf, int);
        ^
 /usr/src/lib/libc/../../include/setjmp.h:58:5: note: 'sigsetjmp' is a
 builtin with type
      'int (struct _jmp_buf *, int)'
 1 error generated.
 *** Error code 1

 Stop in /usr/src/lib/libc.
 *** Error code 1

Might try:
Commenting out CFLAGS=
Setting NO_WERROR= in /etc/make.conf

-- 
--
___
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


OT: Slackware: Starting Servers at Boot

2012-02-02 Thread Chris Maness
I have been using FreeBSD for so long I forgot how to configure
services and startup.  I now also have a Slack box.  What file do I
edit to so that services like named start automagically?  I am aware
lines can be uncommented in inetd.conf, but I want the service running
without spawning from inetd.

Thanks,
Chris Maness
___
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: OT: Slackware: Starting Servers at Boot

2012-02-02 Thread Waitman Gobble
On Feb 2, 2012 12:22 PM, Chris Maness ch...@chrismaness.com wrote:

 I have been using FreeBSD for so long I forgot how to configure
 services and startup.  I now also have a Slack box.  What file do I
 edit to so that services like named start automagically?  I am aware
 lines can be uncommented in inetd.conf, but I want the service running
 without spawning from inetd.

 Thanks,
 Chris Maness
 ___
 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

hmm never tried slackware GNU/Linux but maybe
ntsysv
works?
___
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: OT: Slackware: Starting Servers at Boot

2012-02-02 Thread Noel
On 2/2/2012 2:22 PM, Chris Maness wrote:
 I have been using FreeBSD for so long I forgot how to configure
 services and startup.  I now also have a Slack box.  What file do I
 edit to so that services like named start automagically?  I am aware
 lines can be uncommented in inetd.conf, but I want the service running
 without spawning from inetd.

http://www.freebsd.org/cgi/man.cgi?query=rc.confsektion=5

# /etc/rc.conf
named_enable=YES




___
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: OT: Slackware: Starting Servers at Boot

2012-02-02 Thread Chris Maness
On Thu, Feb 2, 2012 at 1:01 PM, Waitman Gobble gobble...@gmail.com wrote:

 On Feb 2, 2012 12:22 PM, Chris Maness ch...@chrismaness.com wrote:

 I have been using FreeBSD for so long I forgot how to configure
 services and startup.  I now also have a Slack box.  What file do I
 edit to so that services like named start automagically?  I am aware
 lines can be uncommented in inetd.conf, but I want the service running
 without spawning from inetd.

 Thanks,
 Chris Maness
 ___
 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

 hmm never tried slackware GNU/Linux but maybe
 ntsysv
 works?

After more searching it turns out that all that one needs to do is
make the rc.bind executable in the rc.d directory.  Wow, that is as
straight forward as it comes.

Chris
___
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: OT: Slackware: Starting Servers at Boot

2012-02-02 Thread Waitman Gobble
On Feb 2, 2012 1:09 PM, Chris Maness ch...@chrismaness.com wrote:

 On Thu, Feb 2, 2012 at 1:01 PM, Waitman Gobble gobble...@gmail.com
wrote:
 
  On Feb 2, 2012 12:22 PM, Chris Maness ch...@chrismaness.com wrote:
 
  I have been using FreeBSD for so long I forgot how to configure
  services and startup.  I now also have a Slack box.  What file do I
  edit to so that services like named start automagically?  I am aware
  lines can be uncommented in inetd.conf, but I want the service running
  without spawning from inetd.
 
  Thanks,
  Chris Maness
  ___
  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
 
  hmm never tried slackware GNU/Linux but maybe
  ntsysv
  works?

 After more searching it turns out that all that one needs to do is
 make the rc.bind executable in the rc.d directory.  Wow, that is as
 straight forward as it comes.

 Chris

might be dated info but GNU/Linux usually has sep directory for each run
level, so you can have one without X for example. pretty sure ntsysv is a
front end to rc directories with toggle on-off executable bit
___
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


mail server config

2012-02-02 Thread AN
I'm getting ready to install a new mail server.  I want to configure 
sendmail+clamav+spamassassin+mimedefang.  Does anyone have some pointers 
or  howto docs to share?  I read somewhere that spamassassin-milter has 
security issues.  Is mime-defang a better option or should I consider 
something else.  Any help is appreciated.


TIA
___
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: mail server config

2012-02-02 Thread Walt Elam
 I'm getting ready to install a new mail server.  I want to configure
 sendmail+clamav+spamassassin+**mimedefang.


I believe postfix is considered to be much more secure and better then
sendmail overall. I have a mail server and find that postfix was pretty
easy to setup and configure. In addition, it is easy to manage with qshape,
which installs along with Postfix.

The Postfix website has great documentation if you are interested in going
this route: http://www.postfix.org/documentation.html

-Walt
___
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: fixating USB Storage

2012-02-02 Thread bsali...@gmail.com
Please ignore, I forgot that I asked this before. Thanks.

On Thu, Feb 2, 2012 at 4:38 PM, bsali...@gmail.com bsali...@gmail.com wrote:
 Hi,

 How can I fix a USB storage device to always have the same device name
 such as da9 irrespective of other da? devices present.

 Here is the device
 # usbconfig -u 4 -a 2 dump_info
 ugen4.2: USB Flash Drive USB 2.0 at usbus4, cfg=0 md=HOST spd=HIGH
 (480Mbps) pwr=ON

 Thanks



-- 
NOTICE: This email is a one to one communication and not for receiving
any offers or a mass relay of emails. Please refrain from subscribing
this email address to any of the mailing lists. All / any mass emails
to this address will be considered as SPAM and will be reported to FTC
and other authorities. 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


freebsd package update / upgrade

2012-02-02 Thread alexus
What's the procedure on updating packages (not ports), can someone
point me (preferably in a handbook) or else where is fine too...

-- 
http://alexus.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


the WD USB 3.0 My Book Essential

2012-02-02 Thread Henry Olyer
Has anyone gotten one to work?

Either as a USB 2.x or 3.x?  Yes, I know that to do 2.x one must use a
different cable.  I do that.  Because I am wondering what's going on.
 Possibly I just happened to buy a drive that's DOA, I don't know, and I'm
not say that, YET.

I'd like to hear from other purchasers, what's the current buzz on this
product.  I don't want to bash the WD guys, in the past their products have
been wonderful and it may turn out that this will the case here too.

But after a lot of struggling, first with 3.x, now with 2.x, I'm still not
able to get beyond /dev/da0.  And yes I've tried mounting that but that
doesn't work.  And nothing I do seems to produce the needed /dev/da0s1,
which is usually what I see to do a mount.

I've been getting really good help from Roland and others here.  We've been
concentrating on the FBSD side of things and now I'm thinking that's not
where the trouble is.

So again, has anyone gotten a WD My Book Essential drive to work?  With
either USB 2.x or 3.x?
___
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: freebsd package update / upgrade

2012-02-02 Thread Erich Dollansky
Hi,

On Friday 03 February 2012 08:52:07 alexus wrote:
 What's the procedure on updating packages (not ports), can someone
 point me (preferably in a handbook) or else where is fine too...

it is also done with portupgrade. You just have to use -P or -PP.

Check the manual to find out more.

Erich
 
 -- 
 http://alexus.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
 
 
___
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


Possible move back to FreeBSD

2012-02-02 Thread Chris
Hi

I have been using Debian for a few years now (previous BSD user) and I'm 
considering moving back.

Admittedly, I have gotten used to the simplicity of using apt-get to update the 
system.

What will pull me back is if there is an equivalent to use. I do not intend on 
custom kernels, and I don't intend on using ports (it was the many hours spent 
keeping the ports tree current along with installed ports).

If someone would suggest the material to read and perhaps a synopsis of the 
process, I would be happy to do the leg work.

TIA
Chris

Sent from my HTC.___
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: Possible move back to FreeBSD

2012-02-02 Thread mikel king

On Feb 3, 2012, at 12:34 AM, Chris wrote:

 Hi
 
 I have been using Debian for a few years now (previous BSD user) and I'm 
 considering moving back.
 
 Admittedly, I have gotten used to the simplicity of using apt-get to update 
 the system.
 
 What will pull me back is if there is an equivalent to use. I do not intend 
 on custom kernels, and I don't intend on using ports (it was the many hours 
 spent keeping the ports tree current along with installed ports).
 
 If someone would suggest the material to read and perhaps a synopsis of the 
 process, I would be happy to do the leg work.
 
 TIA
 Chris

Hey Chris,

Good to see you again after all this time. I always found the port fetch 
process dead easy for keeping things up to date. I honestly doubt much has 
changed since you last used FreeBSD. However I've been playing around with 
PC-BSD and their PBI system to be pretty good.


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


Re: Possible move back to FreeBSD

2012-02-02 Thread Erich Dollansky
Hi,

On Friday 03 February 2012 12:34:57 Chris wrote:
 Hi
 
 I have been using Debian for a few years now (previous BSD user) and I'm 
 considering moving back.
 
 Admittedly, I have gotten used to the simplicity of using apt-get to update 
 the system.
 
 What will pull me back is if there is an equivalent to use. I do not intend 
 on custom kernels, and I don't intend on using ports (it was the many hours 
 spent keeping the ports tree current along with installed ports).
 
how about pkg_add?

It installs a binary version of the port directly on your machine. As long as 
the binary exists, there is no problem. I experienced in very rare cases that a 
package was not available at the moment I needed at the server I used for 
downloading. Then, I used the ports as a backup.

Erich
___
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: Possible move back to FreeBSD

2012-02-02 Thread Chris
Allow me to apologize for top posting.

I am familliar with pkg_add. I guess I'm more concerned with updating userland 
when sec fixes ate released.

Sent from my HTC.

- Reply message -
From: Erich Dollansky erichfreebsdl...@ovitrap.com
Date: Thu, Feb 2, 2012 11:44 pm
Subject: Possible move back to FreeBSD
To: freebsd-questions@freebsd.org
Cc: Chris rac...@makeworld.com


Hi,

On Friday 03 February 2012 12:34:57 Chris wrote:
 Hi
 
 I have been using Debian for a few years now (previous BSD user) and I'm 
 considering moving back.
 
 Admittedly, I have gotten used to the simplicity of using apt-get to update 
 the system.
 
 What will pull me back is if there is an equivalent to use. I do not intend 
 on custom kernels, and I don't intend on using ports (it was the many hours 
 spent keeping the ports tree current along with installed ports).
 
how about pkg_add?

It installs a binary version of the port directly on your machine. As long as 
the binary exists, there is no problem. I experienced in very rare cases that a 
package was not available at the moment I needed at the server I used for 
downloading. Then, I used the ports as a backup.

Erich

___
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: Possible move back to FreeBSD

2012-02-02 Thread Chris
Heya Mikel!
Yeah, its been a spell. Lookin to climb back onboard. 

Talk soon.

Sent from my HTC.

- Reply message -
From: mikel king mikel.k...@olivent.com
Date: Thu, Feb 2, 2012 11:40 pm
Subject: Possible move back to FreeBSD
To: Chris rac...@makeworld.com
Cc: FreeBSD questions freebsd-questions@freebsd.org



On Feb 3, 2012, at 12:34 AM, Chris wrote:

 Hi
 
 I have been using Debian for a few years now (previous BSD user) and I'm 
 considering moving back.
 
 Admittedly, I have gotten used to the simplicity of using apt-get to update 
 the system.
 
 What will pull me back is if there is an equivalent to use. I do not intend 
 on custom kernels, and I don't intend on using ports (it was the many hours 
 spent keeping the ports tree current along with installed ports).
 
 If someone would suggest the material to read and perhaps a synopsis of the 
 process, I would be happy to do the leg work.
 
 TIA
 Chris

Hey Chris,

Good to see you again after all this time. I always found the port fetch 
process dead easy for keeping things up to date. I honestly doubt much has 
changed since you last used FreeBSD. However I've been playing around with 
PC-BSD and their PBI system to be pretty good.


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

___
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: Possible move back to FreeBSD

2012-02-02 Thread Erich Dollansky
Hi,

On Friday 03 February 2012 12:49:41 Chris wrote:
 Allow me to apologize for top posting.
 
where should be the problem?

 I am familliar with pkg_add. I guess I'm more concerned with updating 
 userland when sec fixes ate released.

portupgrade -P or -PP will do the job then.

Erich
 
 Sent from my HTC.
 
 - Reply message -
 From: Erich Dollansky erichfreebsdl...@ovitrap.com
 Date: Thu, Feb 2, 2012 11:44 pm
 Subject: Possible move back to FreeBSD
 To: freebsd-questions@freebsd.org
 Cc: Chris rac...@makeworld.com
 
 
 Hi,
 
 On Friday 03 February 2012 12:34:57 Chris wrote:
  Hi
  
  I have been using Debian for a few years now (previous BSD user) and I'm 
  considering moving back.
  
  Admittedly, I have gotten used to the simplicity of using apt-get to update 
  the system.
  
  What will pull me back is if there is an equivalent to use. I do not intend 
  on custom kernels, and I don't intend on using ports (it was the many hours 
  spent keeping the ports tree current along with installed ports).
  
 how about pkg_add?
 
 It installs a binary version of the port directly on your machine. As long as 
 the binary exists, there is no problem. I experienced in very rare cases that 
 a package was not available at the moment I needed at the server I used for 
 downloading. Then, I used the ports as a backup.
 
 Erich
 
 
___
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: Possible move back to FreeBSD

2012-02-02 Thread Adam Vande More
On Thu, Feb 2, 2012 at 11:34 PM, Chris rac...@makeworld.com wrote:

 I have been using Debian for a few years now (previous BSD user) and I'm
 considering moving back.

 Admittedly, I have gotten used to the simplicity of using apt-get to
 update the system.

 What will pull me back is if there is an equivalent to use. I do not
 intend on custom kernels, and I don't intend on using ports (it was the
 many hours spent keeping the ports tree current along with installed ports).

 If someone would suggest the material to read and perhaps a synopsis of
 the process, I would be happy to do the leg work.



freebsd-update(1) and pkgng should get you to relative feature parity w/
Debian.   However pkgng just entered beta, and likely won't make it into
the base system anytime soon.  That being said, beta testers are wanted and
it's largely functional.

/usr/ports/UPDATING is still the standard method along with a ports
managment tool of your choice eg portmaster(1).



-- 
Adam Vande More
___
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: Possible move back to FreeBSD

2012-02-02 Thread Chris
Outstanding, thank you. Curious though, how is Gnome looking these days 
(meaning, is it v3 or 2.x).

I have read of the craziness of 3 and the introduction of Unity (albeit that is 
ubuntu).

If 3 is used (or when) I assume it would be closer to what I currently have 
under Sid (and that would be ok) or even 2.x 


Nonetheless, thanks for the info. I'll have time tomorrow to read up a bit and 
perhaps next time I post, it'll be under 9

Sent from my HTC.

- Reply message -
From: Adam Vande More amvandem...@gmail.com
Date: Fri, Feb 3, 2012 12:10 am
Subject: Possible move back to FreeBSD
To: Chris rac...@makeworld.com
Cc: freebsd-questions@freebsd.org freebsd-questions@freebsd.org


On Thu, Feb 2, 2012 at 11:34 PM, Chris rac...@makeworld.com wrote:

 I have been using Debian for a few years now (previous BSD user) and I'm
 considering moving back.

 Admittedly, I have gotten used to the simplicity of using apt-get to
 update the system.

 What will pull me back is if there is an equivalent to use. I do not
 intend on custom kernels, and I don't intend on using ports (it was the
 many hours spent keeping the ports tree current along with installed ports).

 If someone would suggest the material to read and perhaps a synopsis of
 the process, I would be happy to do the leg work.



freebsd-update(1) and pkgng should get you to relative feature parity w/
Debian.   However pkgng just entered beta, and likely won't make it into
the base system anytime soon.  That being said, beta testers are wanted and
it's largely functional.

/usr/ports/UPDATING is still the standard method along with a ports
managment tool of your choice eg portmaster(1).



-- 
Adam Vande More
___
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