Re: Regular Expression Help

2008-11-30 Thread Olivier Nicole
Hi,

> I still don't really understand *why* the above works but I'm trying
> to pick it apart now.

Whenever I have a doubt about regular expression, I use the regexp
coach. It works on Windows, but I find it a very intelligent and
usefull tool.

http://weitz.de/regex-coach/

Best regards,

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


Vishnu is out of the office.

2008-11-30 Thread vishnux




I will be out of the office starting  12/01/2008 and will not return until
12/12/2008.

Please contact helpdesk directly for urgent matters at 043854184.

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


Re: Regular Expression Help

2008-11-30 Thread Matthew Seaman

Drew Tomlinson wrote:

Matthew Seaman wrote:


% perl -p -e 's/cn=([^ ,]+) ([^,]+),/cn=$2 $1,/' < foo.txt 


I still don't really understand *why* the above works but I'm trying to 
pick it apart now.


The RE breaks down like this:

/cn=([^ ,]+) ([^,]+),/
cn= Match literal text 'cn='
   (capture #1 begin
[^ ,]   Character class: anything that is not space or comma
 +  At least one of the above
  ) end capture #1
Match a literal space
(   capture #2 begin
 [^,]   Character class: anything that is not a comma
 +  At least one of the above
  ) end capture #2
   ,Match literal comma

Cheers,

Matthew

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



signature.asc
Description: OpenPGP digital signature


Re: Pasting via ssh causes data loss

2008-11-30 Thread Mel
On Sunday 30 November 2008 17:53:21 Eugene Pimenov wrote:
> 30.11.2008, в 19:36, Mel написал(а):
> > On Sunday 30 November 2008 06:46:59 Eugene Pimenov wrote:
> >
> > Not sure, but can you copy files via cat? As in:
> > cat /tmp/foo | ssh machine "cat - >/tmp/foo"
> >
> > If that isn't truncated, I can only think of clipboard limitations
> > or tty
> > issues.
>
> No, it's not truncated. All of 6060 bytes are copied.
>
> What kind of tty issues/clipboard limitations might it be?

*If* it's a tty issue, should be reproducable with telnet. If it's not, then I 
suggest logging in with ssh -v and see if anything weird comes up.
The oddball out of the box answer would be that some character gets translated 
as EOF from linux to bsd by the term settings, but it's a stretch.

-- 
Mel

Problem with today's modular software: they start with the modules
and never get to the software part.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Purchase of FreeBSD

2008-11-30 Thread Bryant Eadon

Harry Veltman wrote:

Where can I buy it on CD, and how do I know if it is compatible with my 
hardware?
___


Harry,

This may be an obvious statement, but this can be downloaded (an ISO image is an 
exact copy of a CD or DVD -- http://en.wikipedia.org/wiki/ISO_image ).  But, if 
you're on a modem, this download could take a week or more.  :-/


Maybe a local library, school or Internet Cafe would have a faster connection 
and/or CD writer for you to use ?


where / how:
http://www.freebsd.org/where.html

supported Hardware : 
http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/install-hardware.html



Thanks,
Bryant

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


Re: doubt about contribution

2008-11-30 Thread Steven Susbauer
manjunath reddy wrote:
> derar sir ,
>I have downloaded freebsd code and I have made some
> modifications to it. But now feeling difficulty in sending that code to cvs.
> 
>can u please give me the instructions to upload code to CVS
> archieve.
> 
>I am also intrested in knowing the development process of
> freebsd, can u please give more information about it.
> ___
> freebsd-questions@freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-questions
> To unsubscribe, send any mail to "[EMAIL PROTECTED]"
> 
> 

Only a few people have commit access to the tree, things go through them.

For a general overview of how to contribute read through
http://www.freebsd.org/doc/en_US.ISO8859-1/articles/contributing/index.html



signature.asc
Description: OpenPGP digital signature


doubt about contribution

2008-11-30 Thread manjunath reddy
derar sir ,
   I have downloaded freebsd code and I have made some
modifications to it. But now feeling difficulty in sending that code to cvs.

   can u please give me the instructions to upload code to CVS
archieve.

   I am also intrested in knowing the development process of
freebsd, can u please give more information about it.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Is there anything weird I should know about using ipfw on alias addresses?

2008-11-30 Thread Brett Davidson

ifconfig shows the alias addresses correctly bound.
Creating an ipfw rule and testing it from the command line works 
(connects out from master address, not alias)


From website on alias address, the firewall blocks the packets.

The weird thing is that it tags them (in the security log) as coming 
from the master address (not the alias) out the correct interface. In a 
normal world that would mean the packet would match!


What's goin' on here Willis?

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


Re: ports mirror

2008-11-30 Thread Sahil Tandon
Juan Pablo Roig <[EMAIL PROTECTED]> wrote:

> i want trying to make in my lan a mirror of the ports. I have the cvsup
> mirror , and an rsync of all the ports. But in a client i made a cvsup of
> the ports list, but then when i make a port it going to get the tar.bz from
> an external ftp... 

If you want to grab distfiles from a non-default MASTER_SITE when
building ports, look into the MASTER_SITE_OVERRIDE variable.  Search for
it in the Handbook and ports(7).

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


ports mirror

2008-11-30 Thread Juan Pablo Roig
Hi all:
i want trying to make in my lan a mirror of the ports. I have the cvsup
mirror , and an rsync of all the ports. But in a client i made a cvsup of
the ports list, but then when i make a port it going to get the tar.bz from
an external ftp... i have an idea, to nfs mount all the rsynced ports in the
client's /usr/ports/distfiles ... but i think there is another way.
any ideas?
Thanks
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: firewall rules for bitlord, yahoo, limewire

2008-11-30 Thread Norberto Meijome
On Wed, 26 Nov 2008 23:25:21 -0600
"Andrew Gould" <[EMAIL PROTECTED]> wrote:

> The Limewire website says it has versions for Windows, Mac OS X, Linux and
> others, including OS/2 and Solaris.

furthermore, you can just download the source and make it run from within 
Eclipse (with some tweaks regarding to the GUI toolkit...)

B
_
{Beto|Norberto|Numard} Meijome

"Ugly programs are like ugly suspension bridges: they're much more liable to 
collapse than pretty ones, because the way humans (especially engineer-humans) 
perceive beauty is intimately related to our ability to process and understand  
complexity. A language that makes it hard to write elegant code makes it hard 
to write good code."
   Eric Raymond

I speak for myself, not my employer. Contents may be hot. Slippery when wet. 
Reading disclaimers makes you go blind. Writing them is worse. You have been 
Warned.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: firewall rules for bitlord, yahoo, limewire

2008-11-30 Thread Norberto Meijome
On Thu, 27 Nov 2008 12:07:50 +0100 (CET)
Wojciech Puchar <[EMAIL PROTECTED]> wrote:

> > Yeah. Limewire is written in Java (iirc), which makes it extremely
> > easy to port it to any system that can run java.  
> 
> for P2P sharing rtorrent (/usr/ports/net-p2p/rtorrent) works excellent

if you only want BT ... didn't know rtorrent supported gnutella...

_
{Beto|Norberto|Numard} Meijome

"I abhor a system designed for the 'user', if that word is a coded pejorative 
meaning 'stupid and unsophisticated'.
   Ken Thompson

I speak for myself, not my employer. Contents may be hot. Slippery when wet. 
Reading disclaimers makes you go blind. Writing them is worse. You have been 
Warned.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Pasting via ssh causes data loss

2008-11-30 Thread Chris


On Nov 30, 2008, at 2:20 PM, Eugene Pimenov wrote:




On 30 нояб, 23:20, Ivan Voras <[EMAIL PROTECTED]> wrote:


I regularly do copy-pastes of textual data of that size (and  
larger) in

interactive sessions (with text editors) without problems, between
FreeBSD machines and from Linux to FreeBSD machines. Are you sure  
it's
not a problem with your terminal application and not on the server  
side?

(try a different terminal).


Tried a different terminal. iTerm to be exact. The same problem, the
same number of bytes.


I was curious about your situation and set up a couple of tests. Noting
you mentioned iTerm, I thought I might be able to recreate it on a Mac
(OS-X 10.4 with 1.4.3 (100) version Terminal, I had removed iTerm due
to unreliability sometime back).

I copied a 23094 byte program I was working on locally in MacVIM. I  
first did
a cat >testfile then pasted through an ssh terminal.app connection  
over satellite (very

bad connection) into a FreeBSD 7.0 box I built in the last month. At
the far end it received 23094 bytes. sftp of the file to the remote and
diff showed no differences. I then opened an ssh session to a FreeBSD  
server

on my local lan and repeated with the same results. No problems.

The problem does not appear to be obvious or common so there must be  
something

unique about how this situation if you have reproduced it on two
different terminal programs using ssh that would work correctly to other
servers using the same shell and collection method (e.g. cat >blah).

Something missing here. Have you checked if you have
errors shown on the interface of the server? Are there losses if you  
sftp

the files from your machine to the remote (Try pushing a 1.5 MB file and
see if that shows failures). Did you install something other than the  
default

OpenSSH on the server? Do the text files have something other than text
in them or even control sequences for the remote? Just taking  
potshots here.


A somewhat side note here, I would personally never think to move  
files this
way since it's quite possible that content of files can disrupt the  
stream.

I tend to use sftp.


A friend of mine tried from gentoo linux on his laptop (he'is using
yakukake (terminal)), and reproduced the same issue, but different
amount of bytes (3221 for the server that receives 5181 from me).

Is there some stupid sysctl setting? or something like that? I'm so
tired of pasting into a linux box and wget from it into a freebsd box.



 signature.asc
< 1KбПросмотретьЗагрузить

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions- 
[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: pf or ipf rules to allow p2p Limewire through

2008-11-30 Thread Norberto Meijome
On Fri, 28 Nov 2008 14:31:14 +0800
Fbsd1 <[EMAIL PROTECTED]> wrote:

> I think you are missing the fact that limewire does not use dedicated 
> port numbers. Every session uses different port numbers and the remote 
> computers come in on different hight port numbers. Limewire starts off 
> with a proto igmp  multicast packet to the limewire master server where 
> all the other users online computers are listed.

Hi there,

not totally true, it's quite easy. You can configure your client to listen on
1 specific port, disable UPNP, and tell it to advertise itself on the same port
number . Then punch a hole from  your firewall device straight to your client
on that port (both tcp + udp) and you'll be connected QUITE well that way. you
may not make it to ultrapeer in every run, but you just may after a while ;).

B
_
{Beto|Norberto|Numard} Meijome

Quantum Logic Chicken:
  The chicken is distributed probabalistically on all sides of the
  road until you observe it on the side of your course.

I speak for myself, not my employer. Contents may be hot. Slippery when wet.
Reading disclaimers makes you go blind. Writing them is worse. You have been
Warned.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: 5 TB server

2008-11-30 Thread Wojciech Puchar

This is one of the main reasons i want to go with ZFS. Another would be the
filesystem level compression of the data. I have noticed that 3dmax
files (one of
the programs the company works with) are very "compressable" (from 50
Mb to ~ 7Mb).


will it be majority of data???
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Pasting via ssh causes data loss

2008-11-30 Thread Eugene Pimenov


On 30 нояб, 23:20, Ivan Voras <[EMAIL PROTECTED]> wrote:
>
> I regularly do copy-pastes of textual data of that size (and larger) in
> interactive sessions (with text editors) without problems, between
> FreeBSD machines and from Linux to FreeBSD machines. Are you sure it's
> not a problem with your terminal application and not on the server side?
> (try a different terminal).

Tried a different terminal. iTerm to be exact. The same problem, the
same number of bytes.

A friend of mine tried from gentoo linux on his laptop (he'is using
yakukake (terminal)), and reproduced the same issue, but different
amount of bytes (3221 for the server that receives 5181 from me).

Is there some stupid sysctl setting? or something like that? I'm so
tired of pasting into a linux box and wget from it into a freebsd box.

>
>  signature.asc
> < 1KбПросмотретьЗагрузить
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Error Building Qt4-sql

2008-11-30 Thread Warren Liddell
Just updated my ports via csup and i need qt4-sql installed as a 
dependency for KDE4.1.3, but it refuses to let me compile it with the 
following error...




The target system byte order could not be detected!
Turn on verbose messaging (-v) to see the final report.
You can use the -little-endian or -big-endian switch to
./configure to continue.
===>  Script "configure" failed unexpectedly.
Please report the problem to [EMAIL PROTECTED] [maintainer] and attach the
"/usr/ports/databases/qt4-sql/work/qt-x11-opensource-src-4.4.1/src/sql/../..//config.log"
including the output of the failure of your make command. Also, it might be
a good idea to provide an overview of all packages installed on your system
(e.g. an `ls /var/db/pkg`).
*** Error code 1

Stop in /usr/ports/databases/qt4-sql.
** Command failed [exit code 1]: /usr/bin/script -qa 
/tmp/portinstall.13456.0 env make

** Fix the problem and try again.
** Listing the failed packages (-:ignored / *:skipped / !:failed)
! databases/qt4-sql (unknown build error)
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Pasting via ssh causes data loss

2008-11-30 Thread Ivan Voras
Eugene Pimenov wrote:
> Hello everyone,
> 
> I'm not really sure weither it's related to freebsd or ssh.
> 
> When I paste a lot of data (6060 bytes, 60 lines 100 bytes each + ‘\n’)
> via ssh into `cat > test.txt` or the small program, one freebsd receives
> 5181, another receives 3221 bytes.

I regularly do copy-pastes of textual data of that size (and larger) in
interactive sessions (with text editors) without problems, between
FreeBSD machines and from Linux to FreeBSD machines. Are you sure it's
not a problem with your terminal application and not on the server side?
(try a different terminal).




signature.asc
Description: OpenPGP digital signature


Re: FBSD 7.1 BETA2 and RTL8168/8111 problem

2008-11-30 Thread Fernando Apesteguía
On Fri, Nov 28, 2008 at 11:09 PM, Tore Lund <[EMAIL PROTECTED]> wrote:
> Fernando Apesteguía wrote:
>> Hi all,
>>
>> I recently installed FreeBSD 7.1 BETA2 on my system. During
>> installation using FTP option, I could notice the following:
>>
>> After some random time (two, five or six minutes, for instance) the
>> installation stalled and sysinstall lost the connection. I was taken
>> back to the "Select FTP site" screen, and I had to configure my NIC
>> again. Then, the install resumed and I got a usable system (MINIMAL +
>> docs + manpages)
>>
>> But the problem persists. From time to time, it seems the kernel can't
>> see the NIC. It happens during normal operation and no message is
>> shown in /var/log/messages. ifconfig doesn't show my 're0' device, so
>> I can't run dhclient on it and I have to reboot. I have to say that
>> sometimes, even when I reboot, the NIC (RTL8168/8111 PCI Express) is
>> not present.
>>
>> This device works fine in the same computer with either Vista or
>> Fedora 9, though I have to say I had similar problems with earlier
>> versions of Fedora (device disappearing or not present after boot),
>> but after a kernel upgrade everything run smoothly.
>>
>> Does FreeBSD use the same driver than Linux does? Anybody else with
>> this problem?
>>
>> Thanks in advance.
>
> All I can say is that I have the same NIC, which is built into my Asus
> M2A-VM motherboard.  I have used it since March 2008 with no problems at
> all.  For the past three days I have been running 7.1-BETA2, also with
> no problems.  I should like to provide more detail if that can be of any
> help to you.
> --
>Tore
>

Hi again,

As Pegasus remarked, I can see two "PHY write failed" in dmesg. I did
a freebsd-update a couple of days ago and I haven't seen this issue so
far. I'll watch and report it should I get this error again.

Cheers

> ___
> 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: Regular Expression Help

2008-11-30 Thread Drew Tomlinson

Matthew Seaman wrote:

Drew Tomlinson wrote:
I'm attempting to take an ldiff file and flip first/last name order.  
However I can not figure out how to match hyphenated last names.  In 
vim, my current search/replace string is:


%s/cn=\(\w\+\-*\) \(\w\+\),/cn=\2 \1,/gc

This will match:

cn=Smith Joe,

and replace it with:

cn=Joe Smith,

But it will not match:

cn=Smith-Brown Joe,

nor replace it with:

cn=Joe Smith-Brown,

I've tried various incantations of escaping and quantifying yet I can 
not figure out how to do what I want.


Well, assuming that none of the surnames contain ',' and that the 
first ' '
(space) is always the delimiter between the surname and that anything 
else

is forenames ...
% cat foo.txt cn=Smith Joe,
cn=Smith-Brown Joe,
% perl -p -e 's/cn=([^ ,]+) ([^,]+),/cn=$2 $1,/' < foo.txt cn=Joe Smith,
cn=Joe Smith-Brown,

ie. you need a s/// command that understands negated character 
classes.  I
think sed(1) and vi(1) will do that, but I haven't time to look up the 
precise

syntax.  Perl, of course, just does the job for me.


Thank you for your reply.  The particular editor I was attempting to use 
is vim 7.1.315.  However it doesn't like the above string so I tried you 
perl example verbatim.  It works and even handles such lines as:


cn=Smith-Brown Joe & Jane,

to

cn=Joe & Jane Smith-Brown,

which I hadn't considered.

I still don't really understand *why* the above works but I'm trying to 
pick it apart now.


Thanks to you and the others for the replies.

Cheers,

Drew

--
Be a Great Magician!
Visit The Alchemist's Warehouse

http://www.alchemistswarehouse.com

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


Re: Regular Expression Help

2008-11-30 Thread Giorgos Keramidas
On Sun, 30 Nov 2008 09:14:53 -0800, Drew Tomlinson <[EMAIL PROTECTED]> wrote:
> I'm attempting to take an ldiff file and flip first/last name order.
> However I can not figure out how to match hyphenated last names.  In
> vim, my current search/replace string is:
>
> %s/cn=\(\w\+\-*\) \(\w\+\),/cn=\2 \1,/gc

Hi Drew,

Depending on the VI implementation you are using this may not work
because some versions don't support `\w' as a character class.  The
regular expession, when translated to Perl, works fine though:

  $ cat foo
  cn=Smith Joe,
  cn=Smith-Brown Joe,
  $ perl -pe 's/^cn=(\w+-*\w+) (\w+),/cn=$2 $1,/' foo
  cn=Joe Smith,
  cn=Joe Smith-Brown,
  $

So you can just use Perl and the `extended regexp' syntax that includes
`\w', `\d' and other special character classes.

If you really _have_ to use VI to do this sort of replacement though,
you may have to write the fully expanded form of `\w' to make this work:

  %s/^cn=\([A-Za-z]\+[A-Za-0-9]*[A-Za-z]*\) 
\([A-Za-z]\+[A-Za-0-9]*[A-Za-z]*\),/cn=\2 \1,/

Using the same \(...\) expression for both the `name' and `surname' part
may be useful if you want to switch _back_ to the original format too,
since it will swap words for all of the following:

  cn=Smith Joe,
  cn=Smith-Brown Joe,
  cn=Smith Marie,
  cn=Smith Anne-Marie,
  cn=Smith-Brown Anne-Marie,

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


Re: Regular Expression Help

2008-11-30 Thread Matthew Seaman

Drew Tomlinson wrote:
I'm attempting to take an ldiff file and flip first/last name order.  
However I can not figure out how to match hyphenated last names.  In 
vim, my current search/replace string is:


%s/cn=\(\w\+\-*\) \(\w\+\),/cn=\2 \1,/gc

This will match:

cn=Smith Joe,

and replace it with:

cn=Joe Smith,

But it will not match:

cn=Smith-Brown Joe,

nor replace it with:

cn=Joe Smith-Brown,

I've tried various incantations of escaping and quantifying yet I can 
not figure out how to do what I want.


Well, assuming that none of the surnames contain ',' and that the first ' '
(space) is always the delimiter between the surname and that anything else
is forenames ... 

% cat foo.txt 
cn=Smith Joe,

cn=Smith-Brown Joe,
% perl -p -e 's/cn=([^ ,]+) ([^,]+),/cn=$2 $1,/' < foo.txt 
cn=Joe Smith,

cn=Joe Smith-Brown,

ie. you need a s/// command that understands negated character classes.  I
think sed(1) and vi(1) will do that, but I haven't time to look up the precise
syntax.  Perl, of course, just does the job for me.

Cheers,

Matthew

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



signature.asc
Description: OpenPGP digital signature


Re: 5 TB server

2008-11-30 Thread Wojciech Puchar

I perfectly agree with you and yes there might be monsters out there
in the ZFS on FreeBSD but the fact that us (the community) embrace the
change and apply it makes the development of it possible and even faster.
I don't want to offend anyone or to start a war this is just my opinion.


everything is fine as long as ZFS is fully optional feature as today.

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


Re: for awk experts only.

2008-11-30 Thread Giorgos Keramidas
On Sun, 30 Nov 2008 09:15:15 -0800, Gary Kline <[EMAIL PROTECTED]> wrote:
>On Sun, Nov 30, 2008 at 11:47:29AM +0200, Giorgos Keramidas wrote:
>> Don't do this with a long stream of if/else/.../else blocks.  AWK is
>> a pattern based rule-language.  You can apply different blocks of
>> code to lines that match patterns like this:
>>
>> $3 ~ /adjective/ { print $1,"adj." }
>> $3 ~ /noun/  { print $1,"n." }
>> $3 ~ /verb/  { print $1,"v." }
>
> Thank you!  Would I enclose the three lines with "BEGIN", and end with
> an "exit;" at the end?

Nope.  None of the two.

'BEGIN' has a special meaning in awk patterns.  It means "run this block
of code before you start reading any input records".

If you 'exit' somewhere in a code block, then awk will terminate the
script after the first line that matches the relevant pattern.  This is
probably not quite what you want when awk filters through a long list of
words.

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


Re: Regular Expression Help

2008-11-30 Thread prad
On Sun, 30 Nov 2008 09:14:53 -0800
Drew Tomlinson <[EMAIL PROTECTED]> wrote:

> I'm attempting to take an ldiff file and flip first/last name order.
>
you can try using sh (i'm using zsh)

file data.txt has the following:

joe brown
joe brown-smith


file t.sh is coded as:

#!/usr/local/bin/zsh
#
while read var; do
f=${var% *}
l=${var#* }
echo $l, $f
done < $1


then you just run it as 
t.sh data.txt

-- 
In friendship,
prad

  ... with you on your journey
Towards Freedom
http://www.towardsfreedom.com (website)
Information, Inspiration, Imagination - truly a site for soaring I's
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: for awk experts only.

2008-11-30 Thread Gary Kline
On Sun, Nov 30, 2008 at 11:47:29AM +0200, Giorgos Keramidas wrote:
> On Sat, 29 Nov 2008 20:59:51 -0800, Gary Kline <[EMAIL PROTECTED]> wrote:
> > wordnet/wn prints the string "noun" out whereas I'd rather it simply
> > printed "n."  Is there a way of making this substitution using awk?
> > (I've never used awk except as a cmdline filter.)
> >
> > The following fails:
> >
> > wn foot -over |grep Overview |awk
> > {if(!strcmp($3,"noun"))$3="n."; '{printf("%s %s\n", $4, $3);}}'
> >
> > If there are any shortcuts, please clue me in!
> 
> Don't do this with a long stream of if/else/.../else blocks.  AWK is a
> pattern based rule-language.  You can apply different blocks of code to
> lines that match patterns like this:
> 
> $3 ~ /adjective/ { print $1,"adj." }
> $3 ~ /noun/  { print $1,"n." }
> $3 ~ /verb/  { print $1,"v." }

Thank you!  Would I enclose the three lines with "BEGIN", and end with 
an
"exit;" at the end?

> 

-- 
 Gary Kline  [EMAIL PROTECTED]  http://www.thought.org  Public Service Unix
http://jottings.thought.org   http://transfinite.thought.org


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


Regular Expression Help

2008-11-30 Thread Drew Tomlinson
I'm attempting to take an ldiff file and flip first/last name order.  
However I can not figure out how to match hyphenated last names.  In 
vim, my current search/replace string is:


%s/cn=\(\w\+\-*\) \(\w\+\),/cn=\2 \1,/gc

This will match:

cn=Smith Joe,

and replace it with:

cn=Joe Smith,

But it will not match:

cn=Smith-Brown Joe,

nor replace it with:

cn=Joe Smith-Brown,

I've tried various incantations of escaping and quantifying yet I can 
not figure out how to do what I want.


Please show me my error.

Thanks,

Drew

--
Be a Great Magician!
Visit The Alchemist's Warehouse

http://www.alchemistswarehouse.com

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


Re: Pasting via ssh causes data loss

2008-11-30 Thread Eugene Pimenov


30.11.2008, в 19:36, Mel написал(а):


On Sunday 30 November 2008 06:46:59 Eugene Pimenov wrote:

Not sure, but can you copy files via cat? As in:
cat /tmp/foo | ssh machine "cat - >/tmp/foo"

If that isn't truncated, I can only think of clipboard limitations  
or tty

issues.



No, it's not truncated. All of 6060 bytes are copied.

What kind of tty issues/clipboard limitations might it be?





--
Mel

Problem with today's modular software: they start with the modules
   and never get to the software part.


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


Re: Pasting via ssh causes data loss

2008-11-30 Thread Mel
On Sunday 30 November 2008 06:46:59 Eugene Pimenov wrote:
> Hello everyone,
>
> I'm not really sure weither it's related to freebsd or ssh.
>
> When I paste a lot of data (6060 bytes, 60 lines 100 bytes each +
> ‘\n’) via ssh into `cat > test.txt` or the small program, one freebsd
> receives 5181, another receives 3221 bytes.
>
> The number of bytes freebsd receives are always the same.
>
> I can't reproduce this on linux (OpenSSH 4.3p2 on debian and OpenSSH
> 4.7p1 on 2 gentoo boxes). Also, I have one freebsd box without this
> problem (7.0-STABLE, openssh 4.5p1).
>
> Source of the small program:
>
>#include 
>
>int main()
>{
>char buf[1];
>size_t readed = 0;
>while(!feof(stdin)) {
>readed+=fread(buf, 1, sizeof(buf), stdin);
>}
>
>printf("I've received %d bytes\n", readed);
>return 0;
>}
>
> Versions of sshd are “OpenSSH_4.5p1 FreeBSD-20061110, OpenSSL 0.9.8e
> 23 Feb 2007”. FreeBSD versions are FreeBSD 7.0-BETA4 and FreeBSD 7.0-
> RELEASE.
>
> Why is it happening? What should I do to stop this? It's pretty
> annoying.

Not sure, but can you copy files via cat? As in:
cat /tmp/foo | ssh machine "cat - >/tmp/foo"

If that isn't truncated, I can only think of clipboard limitations or tty 
issues.

-- 
Mel

Problem with today's modular software: they start with the modules
and never get to the software part.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: 5 TB server

2008-11-30 Thread Valentin Bud
On Fri, Nov 28, 2008 at 11:55 PM, Karl Vogel <[EMAIL PROTECTED]> wrote:
>>> On Fri, 28 Nov 2008 14:45:31 -0500,
>>> I spewed something along the lines of:
>
> K> In my experience, completely new filesystems or operating systems need at
> K> least 5 years in the field to weed out all the weird corner-cases.  I might
> K> trust ZFS on Sun hardware (*with* vendor support) at this point, but I'd
> K> wait awhile before trying it on anything else.
>
>>> On Fri, 28 Nov 2008 21:28:51 +0100,
>>> Wojciech Puchar <[EMAIL PROTECTED]> said:
>
> W> if it will ever be good filesystem, it will be no longer ZFS. just the
> W> ideas is in big part wrong.
>
>   I'm not trying to start a religious war, but at least one idea in ZFS is
>   worth its weight in platinum: end-to-end file-integrity checks.  ZFS can
>   (and does) find and correct file errors introduced by disk firmware and
>   media problems.  With the sheer volume of stuff being stored these days,
>   that capability (in any filesystem) is going to be crucial.

This is one of the main reasons i want to go with ZFS. Another would be the
filesystem level compression of the data. I have noticed that 3dmax
files (one of
the programs the company works with) are very "compressable" (from 50
Mb to ~ 7Mb).


thank you,
v

>
> --
> Karl Vogel  I don't speak for the USAF or my company
>
> I think that's how Chicago got started.  A bunch of people in New York
> said, "Gee, I'm enjoying the crime and the poverty, but it just isn't
> cold enough.  Let's go west."   --Richard Jeni
> ___
> 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: 5 TB server

2008-11-30 Thread Valentin Bud
On Fri, Nov 28, 2008 at 9:45 PM, Karl Vogel <[EMAIL PROTECTED]> wrote:
>>> On Fri, 28 Nov 2008 15:48:45 +0200,
>>> "Valentin Bud" <[EMAIL PROTECTED]> said:
>
> V> I have to come up with a solution for a company that has as we speak 4 TB
> V> of data spread among 3 computers with lots of HDDs.  Of course I've
> V> recommend them to buy a server for that storage capacity and for data
> V> organization.
>
>   Good idea.  We had a similar problem here; a SuperMicro server tanked,
>   and the company that provided the warranty went bankrupt, so all we had
>   were 12 perfectly good 400-Gb SATA drives and nowhere to put them.
>
>   The drives were the big-cost item, so I didn't want to just dump them.
>   We finally bought two empty IBM x3400 8-bay enclosures plus some IBM
>   SAS 3.5" hot-swap trays, and it's working like a charm.
>
> V> I thought of going on the ZFS way (on FreeBSD of course) with some raidz.
>
>   In my experience, completely new filesystems or operating systems need
>   at least 5 years in the field to weed out all the weird corner-cases.
>   I might trust ZFS on Sun hardware (*with* vendor support) at this point,
>   but I'd wait awhile before trying it on anything else.

I perfectly agree with you and yes there might be monsters out there
in the ZFS on FreeBSD but the fact that us (the community) embrace the
change and apply it makes the development of it possible and even faster.
I don't want to offend anyone or to start a war this is just my opinion.

>
>   This isn't a slam at ZFS or the FreeBSD porters, it's just recognition
>   of the fact that some types of software development are *not* time-
>   compressible, regardless of who's doing the work.
>
> V> One of the problems is that the server will stay in their office so it
> V> has to be quite silent.
>
>   Not a good idea, especially if this data is their bread-and-butter.
>   You can walk out the door with a system this size on your shoulder,
>   so I'd recommend a locked room with reasonable cooling and *clean*
>   power.  You don't need a 10-foot-tall zillion-dollar Liebert A/C,
>   but you absolutely need a UPS that can take care of power spikes;
>   the more moderate the environment, the less likely you are to have a
>   hardware failure.

I have thought about a decent UPS and already told them that they should
install an alarm system of some sort because neither I nor any IT company
can warranty them physical security. The room is not possible :|, that
would have
been great. What do you think about a rack of some sort?

>
>   I don't use disk mirroring because 99% of our problems come from humans
>   rather than hardware.  If someone zaps the wrong file, a mirror will
>   simply replicate that mistake; we have two matching servers in separate
>   rooms, and we run rsync nightly to back up the production box without
>   deleting any files.  I also run hourly backups on the production box
>   to store anything that's been modified in the last 60 minutes, which
>   gives us a nice file history and takes care of most recovery problems.

This is the actual technology i apply ATM in one of the offices in which
i have 2 BSD boxes. I thought about using RAID because of the amount of data
and the safety of it and plus the second box is out of the question ATM :|.

>
>   With two servers, I can use basic UFS filesystems and get fine I/O
>   performance with minimum maintenance.

thank you for your thoughts,
v

>
> --
> Karl Vogel  I don't speak for the USAF or my company
>
> The first product Motorola started to develop was a record player for cars.
> At that time, the most known player on the market was Victrola, so they
> called themselves Motorola.   --possibly-true item for a lull in conversation
> ___
> 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: does not understand "df -H"

2008-11-30 Thread Sahil Tandon
Tsu-Fan Cheng <[EMAIL PROTECTED]> wrote:

> Hi,
>I have a pretty basic question: when I "df -H" my disk, the numbers
> cant add up,
> 
> 
> Filesystem SizeUsed   Avail Capacity  Mounted on
> /dev/ad0c  484G429G 17G96%/ad0c
> 
> 
> there should be more disk space available based on what is shown. why
> is this like that??

This is default behavior.  From tunefs(8):

-m minfree
 Specify the percentage of space held back from normal users; the
 minimum free space threshold.  The default value used is 8%.
 Note that lowering the threshold can adversely affect perfor-
 mance:

 +o  Settings of 5% and less force space optimization to always be
 used which will greatly increase the overhead for file
 writes.

 +o  The file system's ability to avoid fragmentation will be
 reduced when the total free space, including the reserve,
 drops below 15%.  As free space approaches zero, throughput
 can degrade by up to a factor of three over the performance
 obtained at a 10% threshold.

Your df output suggests your minfree is set to the default 8%; to
confirm this:

% dumpfs /dev/ad0c | grep minfree | cut -f 1-2

-- 
Sahil Tandon <[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: 5 TB server

2008-11-30 Thread Valentin Bud
On Fri, Nov 28, 2008 at 8:38 PM, Modulok <[EMAIL PROTECTED]> wrote:
> On 11/28/08, Valentin Bud <[EMAIL PROTECTED]> wrote:
>> Hello community,
>>
>>  I have to come up with a solution for a company that has as we speak
>> 4 TB of data spread among 3 computers with lots of HDDs. Of course
>> i've recommend
>> them to buy a server for that storage capacity and for data organization.
>>
>>  I thought of going on the ZFS way (on FreeBSD of course) with some
>> raidz. One of the problems
>> is that the server will stay in their office so it has to be quite silent.
>>
>>  I honestly don't know what hardware to look for so if you have any
>> suggestions
>> i'm more than open to hear them.
>>
>> a great day,
>> v
>
> I'm not sure what kind of fans everyone here is running, with all
> these complaints about noise...
>
> For a single server sitting in an office, use a regular desktop case
> with some good 12cm fans. Get a few fan-speed-controllers to reduce
> the RPMs a little and you can have a computer with several disks in it
> that is damn near silent, even when it is sitting right next to you.
> Put a good power supply unit, with a slow 14cm fan in it and you can't
> hear the computer at all. As far as heat goes, a well ventilated
> aluminum desktop case disperses heat very, very well, permitting the
> reduction of fan speed.
>
> I have a server built this way sitting not 2 feet from me, which
> contains 5 hard drives providing 24/7 file storage via samba for the
> entire local area network, and unless one puts their ear against the
> case, it's difficult to tell if it is even running...even under heavy
> load. (This is in a quiet room.) As far as heat goes, the case blows
> out room temperature air and all components are cold to the touch.
> Built for around...$800-$900 USD. (I'm not exactly sure on the figure,
> as some components have been upgraded over the years.)
>
> Case: Lian Li PC-7B Plus II ATX Mid Tower. Best case ever. Cheap.
> Simple. Roomy. Very well ventilated. I now personally own 4 of these
> cases. No regrets.  Ditch the factory fans though. Replace them with a
> few Zalman 12cm fans. These usually come with a resistor so you can
> reduce the fan speed (and noise).
>
> Processor: Whatever. I went with a cheap dual core Opteron at the time.
> Board: I usually stick with Tyan. whatever fits your processor, your
> budget and provides you with enough SATA headers. For a simple file
> server, stick with a lower-end single-socket board. Unless you plan to
> do some serious number crunching or have a lot of money to spend, you
> don't need the extra processors sitting around doing nothing, with
> their fans making noise.
>
> Memory: Start with a few (say 2) gigs, it's cheap.
> Power Supply Unit: I've had good luck with Thermaltake W0144 Purepower
> RX. They use 14cm fans which are silent, but move a lot of air and
> I've had zero problems with them. The ability to only plugin the power
> components you require helps maintain good airflow in the case.
>
> Network: Not all network cards are created equal! Go with one (or two)
> PCI Intel network cards. If it's based on the Intel PRO/1000GT, it
> will be supported by the em(4) driver on FreeBSD. I use the Intel
> PWLA8391GT. Zero problems.
>
> As far as hard drives go, I've found recently that Western Digital
> drives are quite silent, even under heavy read/writes, but I haven't
> tried Seagate or any of the other major drive manufacturers in a long
> time, so they may be about the same.

Thanks for sharing. I'm just wondering what is the maximum number
of hard disk a motherboard can support, i mean desktop motherboards.
And is it easy to attach a storage unit in case you want more space?
 This company i'm talking about is growing with 1 Tb per year. I have talked
to them to archive the data but it's out of discusion because they almost
always need random parts of old projects and they want to access it ASAP.

a great day,
v

>
> With a little work, your goal of a silent, high-capacity server is
> quite attainable. It can be pretty cheap to build too.
> -Modulok-
>
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Unix program that sends email directly using MX record

2008-11-30 Thread Sahil Tandon
Ott K?stner <[EMAIL PROTECTED]> wrote:

> Peter Boosten wrote:
>
>> The most recent vulnerabilities of Postfix are from August and September
>> 2008, and I still use it. Also I use (with great happyness) Sendmail on
>> two machines, without any problems. The only problem ever caused was by
>> clamav.
>>
> Would be interesting to know, what kind of problems have been there with 
> CLAMAV?

None whatsoever.  I have used it for several years on FreeBSD without
incident.  There are, from time to time, some security vulnerabilities,
but they are handled swiftly by both the clamav developers and the
security/clamav port maintainer.

-- 
Sahil Tandon <[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: Problem about ppp -nat

2008-11-30 Thread Pongthep Kulkrisada
Hi all,

> set log phase chat connect carrier link ipcp ccp ID0 TUN command
I still can't dial using this configuration...

# ppp -background isp
Loading /lib/libalias_cuseeme.so
Loading /lib/libalias_ftp.so
Loading /lib/libalias_irc.so
Loading /lib/libalias_nbt.so
Loading /lib/libalias_pptp.so
Loading /lib/libalias_skinny.so
Loading /lib/libalias_smedia.so
Working in background mode
Using interface: tun0
Warning: carrier: Invalid log value
Warning: link: Invalid log value
Warning: usage: set log [local] 
[+|-]all|async|cbcp|ccp|chat|command|connect|debug|dns|hdlc|id0|ipcp|lcp|lqm|phase|physical|radius|sync|tcp/ip|timer|tun...
Attempting redial
Attempting redial
Attempting redial

I then removed ``carrier'' and ``link''. It always keeps redialing without
hearing dialing tone from the modem. So I removed ``connect'' again. The result 
was still the same.

> Try /dev/cuaa0.  At least in the olden days, cuad0 was configured more
> for dialin rather than dialout.  This may? explain the next two lines:
It keeps redialing without hearing any tone from the modem. So I switched back 
to /dev/cuad0. Then dial; now I hear dialing tone from the modem but warning 
message of ``Child failed (errdead)'' occured then line dropped. And can not 
connect. I tried it many times. Note that /dev/cuad0 appeared in my 
/usr/share/examples/ppp/ppp.conf.sample, not /dev/cuaa0. If I remember 
correctly I changed from cuaa0 to cuad0 when I upgraded from FBSD5.4R to 
FBSD6.2R.
[...]
Working in background mode
Using interface: tun0
Child failed (errdead)

>>  set ctsrts off   # enables software flow control
>>  set accmap 000a  # comments out these 2 lines for hardware flow control
> Not sure why you don't want to use hardware flow control?  Is this with
> a regular external modem?  Anyway, I've always used ctsrts (with cuaa0).
5 year ago, I downloaded this ppp.conf from some web site. But anyway, I did 
follow your suggestion i.e. hardware flow control. It still doesn't work as 
``Child failed''. Actually I don't know so much in this area (flow control). I 
only code C on *Unix. I rarely do this kind of things e.g. system setup or 
configuration. And yes, it is a regular external modem.

>>  add! default HISADDR   # Add a (sticky) default route
>>  [...]
>>  add 0 0 HISADDR
> You probably don't want both those add statements.  Try taking out the
> first one, and replacing the last one with the add! default HISADDR.
I changed it before dialing.

> Unsure if you need an 'enable pap' as well, maybe default.  Can't hurt.
I added it before dialing. But all failed. I think it is probably caused by
ipdivert.

> Anyway, some extra logging should show you when and how it fails, if it
> still does ..
Nov 30 17:00:00 bsdhost newsyslog[960]: logfile turned over due to size>100K
Nov 30 17:00:16 bsdhost ppp[977]: Phase: Using interface: tun0
Nov 30 17:00:16 bsdhost ppp[977]: Phase: deflink: Created in closed state
Nov 30 17:00:16 bsdhost ppp[977]: tun0: Command: default: ident user-ppp 
VERSION (built COMPILATIONDATE)
Nov 30 17:00:16 bsdhost ppp[977]: tun0: Command: default: set device /dev/cuad0
Nov 30 17:00:16 bsdhost ppp[977]: tun0: Command: default: set speed 115200
Nov 30 17:00:16 bsdhost ppp[977]: tun0: Command: default: disable pred1
Nov 30 17:00:16 bsdhost ppp[977]: tun0: Command: default: deny pred1
Nov 30 17:00:16 bsdhost ppp[977]: tun0: Command: default: disable lqr
Nov 30 17:00:16 bsdhost ppp[977]: tun0: Command: default: deny lqr
Nov 30 17:00:16 bsdhost ppp[977]: tun0: Command: default: set dial ABORT BUSY 
ABORT NO\sCARRIER TIMEOUT 5   "" AT OK-AT-OK ATE1Q0 OK \dATDT\T 
TIMEOUT 180 CONNECT
Nov 30 17:00:16 bsdhost ppp[977]: tun0: Command: default: set redial 3 20
Nov 30 17:00:16 bsdhost ppp[977]: tun0: Command: default: enable dns
Nov 30 17:00:16 bsdhost ppp[977]: tun0: ID0: 0x28389e78 = 
fopen("/etc/ppp/ppp.conf", "r")
Nov 30 17:00:16 bsdhost ppp[977]: tun0: Command: ego: set phone 0123456789
Nov 30 17:00:16 bsdhost ppp[977]: tun0: Command: ego: set authname
[EMAIL PROTECTED]
Nov 30 17:00:16 bsdhost ppp[977]: tun0: Command: ego: set authkey **
Nov 30 17:00:16 bsdhost ppp[977]: tun0: Command: ego: set timeout 0
Nov 30 17:00:16 bsdhost ppp[977]: tun0: Command: ego: set openmode active
Nov 30 17:00:16 bsdhost ppp[977]: tun0: Command: ego: accept pap
Nov 30 17:00:16 bsdhost ppp[977]: tun0: Command: ego: enable pap
Nov 30 17:00:16 bsdhost ppp[977]: tun0: Command: ego: set ifaddr 10.0.0.1/0 
10.0.0.2/0 255.255.255.0 0.0.0.0
Nov 30 17:00:16 bsdhost ppp[977]: tun0: Command: ego: add! default HISADDR
Nov 30 17:00:16 bsdhost ppp[977]: tun0: ID0: 10 = socket(17, 3, 0)
Nov 30 17:00:16 bsdhost ppp[977]: tun0: ID0: -1 = write(10, data, 140)
Nov 30 17:00:16 bsdhost ppp[978]: tun0: ID0: 0x28389e78 = 
fopen("/var/run/tun0.pid", "w")
Nov 30 17:00:16 bsdhost ppp[978]: tun0: Phase: PPP Started (background mode).
Nov 30 17:00:16 bsdhost ppp[978]: tun0: Phase: bundle: Establish
Nov 30 17:00:16 bsdhost ppp[978]: tun0: Phase: def

Re: does not understand "df -H"

2008-11-30 Thread Wojciech Puchar

Filesystem SizeUsed   Avail Capacity  Mounted on
/dev/ad0c  484G429G 17G96%/ad0c


there should be more disk space available based on what is shown. why
is this like that??


man newfs
man tunefs

you used default options with newfs i think, including 8% space 
reservation

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


does not understand "df -H"

2008-11-30 Thread Tsu-Fan Cheng
Hi,
   I have a pretty basic question: when I "df -H" my disk, the numbers
cant add up,


Filesystem SizeUsed   Avail Capacity  Mounted on
/dev/ad0c  484G429G 17G96%/ad0c


there should be more disk space available based on what is shown. why
is this like that??

thanks!!

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


Re: Temporarily blocking ports

2008-11-30 Thread Jos Chrispijn

Thank you all for your help!
Jos Chrispijn
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Unix program that sends email directly using MX record

2008-11-30 Thread Peter Boosten



On 30 nov 2008, at 13:51, Ott Köstner <[EMAIL PROTECTED]> wrote:


Peter Boosten wrote:

The most recent vulnerabilities of Postfix are from August and  
September
2008, and I still use it. Also I use (with great happyness)  
Sendmail on
two machines, without any problems. The only problem ever caused  
was by

clamav.


Would be interesting to know, what kind of problems have been there  
with CLAMAV?
Just to be aware. I am currently using clamav Clamav>-0.94.2 on some FreeBSD computers.




It has been some time ago, on openbsd, and the problem existed between  
clamscan vs clamdscan. Never had any problems with clamav from the  
ports in freebsd.


Peter
--
HTTP://www.boosten.org___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Anybody familiar with "publib"??

2008-11-30 Thread Ruben de Groot
On Sat, Nov 29, 2008 at 02:51:23PM -0800, Gary Kline typed:
> 
> People,
> 
> I found a neat function in publib that should do what I want, but adding 
> either
> 
> #imclude   // as per man publib
> 
> OR
> 
> #include "/usr/local/include/publib.h"
> 
> fails.  Yes, I am adding "-lpub" to the enc of gcc.  Still bombs.  Anybody 
> know
> why?  Prev'ly when I've used the publib functions, I've had to move/copy a 
> slew
> of them into my private build.  Be nice if this just-worked!

Fails/bombs how?
We're not all psychics here
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Unix program that sends email directly using MX record

2008-11-30 Thread Ott Köstner

Peter Boosten wrote:


The most recent vulnerabilities of Postfix are from August and September
2008, and I still use it. Also I use (with great happyness) Sendmail on
two machines, without any problems. The only problem ever caused was by
clamav.

  
Would be interesting to know, what kind of problems have been there with 
CLAMAV?
Just to be aware. I am currently using clamav -0.94.2 
on some FreeBSD computers.


Regards,
O.K.


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


Re: FreeBSD 4.8: can't load kernel after doing "cp -R /" to another disk

2008-11-30 Thread Tijl Coosemans
On Sunday 30 November 2008 06:57:29 [EMAIL PROTECTED] wrote:
>>> Hello, everyone. This is the problem: our SCSI disk with FreeBSD
>>> 4.8 on it has been failing recently, so I copied its root partition
>>> to a fresh IDE disk with cp -pR and
>> 
>> You should use dump and restore to copy the root partition, see:
> 
> I'd done that before trying cp -pR, as outlined by rse@:
> 
> dump -L -0 -f- /old | (cd /new && restore -r -v -f-)
> http://people.freebsd.org/~rse/mirror/
> 
> which isn't too different. I think I know what the problem is: I made
> the new single slice and FreeBSD partition on it and ran newfs -U on
> it using the latest FreeBSD 5.x livecd toolkit, and later 4.8 can't
> even mount that partition (mount /dev/ad0s1a /mnt) failing with
> "incorrect superblock", so I think its /boot/loader can't load the
> kernel because of FS issues (but strangely enough pressing "?" at the
> boot loader prompt lists directory entries of the root FS just fine).
> It turns out UFS isn't upwards compatible from releases 4.8 -> 5.5.
> I'll try running newfs -U from 4.8. Last time I checked many 4.8
> binaries couldn't run due to disk errors, I hope newfs runs ok...

You need to create a UFS1 file system. Also, root file systems
usually don't have soft updates (-U) enabled.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: for awk experts only.

2008-11-30 Thread Giorgos Keramidas
On Sat, 29 Nov 2008 20:59:51 -0800, Gary Kline <[EMAIL PROTECTED]> wrote:
>   wordnet/wn prints the string "noun" out whereas I'd rather it simply
>   printed "n."  Is there a way of making this substitution using awk?
>   (I've never used awk except as a cmdline filter.)
>
>   The following fails:
>
> wn foot -over |grep Overview |awk
> {if(!strcmp($3,"noun"))$3="n."; '{printf("%s %s\n", $4, $3);}}'
>
>   If there are any shortcuts, please clue me in!

Don't do this with a long stream of if/else/.../else blocks.  AWK is a
pattern based rule-language.  You can apply different blocks of code to
lines that match patterns like this:

$3 ~ /adjective/ { print $1,"adj." }
$3 ~ /noun/  { print $1,"n." }
$3 ~ /verb/  { print $1,"v." }

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


Re: pf or ipf rules to allow p2p Limewire through

2008-11-30 Thread Fbsd1

>> [EMAIL PROTECTED] wrote:


So on the Limewire "Advanced -> Firewall" config page enter a port
number, such as 6346 in both the "Listen on Port" and the "Manual Port
Forward" boxes.

Then after your NAT rule in pf.conf enter something like the following:

rdr on $ExtIF proto tcp from any to any port 6346 -> 192.168.10.2 port 
6346


and a corresponding filter pass rule:

in both the "Listen on Port" and the "Manual Port
Forward" boxes.

192.168.10.2 is my desktop machine where I use Limewire. It works just 
fine.





Thank you for the solution to this problem.

I was un-aware Limewire had it's own firewall configuration options.
In Limewire version 4.18 Tools/Options/Advanced/Firewall I entered the 
same port number  in both the "Listen on Port" and the "Manual Port 
Forward" option fill in boxes.  Then in IPF rules added these 2 lines.


pass out quick on $oif proto igmp from any to any keep state
pass out quick on $oif proto tcp  from any to any port =  flags S 
keep state


Each XP box on the lan running Limewire gets it's own unique port number 
and the corresponding firewall rule. No need for NAT RDR rules.

Limewire works fine and my firewall is tight as every.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"