Solaris Tips: Difference between revisions
mNo edit summary |
m (→rsync) |
||
Line 1: | Line 1: | ||
== rsync == | == rsync == | ||
I was getting an error when transferring some files | |||
<geshi lang="bash"> | |||
$ rsync -e ssh ... | |||
rsync: error writing 4 unbuffered bytes - exiting: Broken pipe | |||
rsync error: error in rsync protocol data stream (code 12) at io.c(464) | |||
$ rsync --version | |||
rsync version 2.5.4 protocol version 26 | |||
Copyright (C) 1996-2002 by Andrew Tridgell and others | |||
<http://rsync.samba.org/> | |||
Capabilities: 64-bit files, socketpairs, hard links, symlinks, batchfiles, no IPv6, | |||
64-bit system inums, 64-bit internal inums | |||
</geshi> | |||
I compiled a more recent rsync (2.6.9), and it fixed the issue. | |||
I have a user installed rsync, and a locked down ssh. In order to rsync files, I use this command. | I have a user installed rsync, and a locked down ssh. In order to rsync files, I use this command. |
Revision as of 03:26, 6 December 2007
rsync
I was getting an error when transferring some files <geshi lang="bash"> $ rsync -e ssh ... rsync: error writing 4 unbuffered bytes - exiting: Broken pipe rsync error: error in rsync protocol data stream (code 12) at io.c(464) $ rsync --version rsync version 2.5.4 protocol version 26 Copyright (C) 1996-2002 by Andrew Tridgell and others <http://rsync.samba.org/> Capabilities: 64-bit files, socketpairs, hard links, symlinks, batchfiles, no IPv6,
64-bit system inums, 64-bit internal inums
</geshi>
I compiled a more recent rsync (2.6.9), and it fixed the issue.
I have a user installed rsync, and a locked down ssh. In order to rsync files, I use this command. <geshi lang="bash"> rsync -e ssh --rsync-path=~/bin/rsync -avz --progress source dest </geshi>
vim Solaris 5.8
source-highlight-2.7
<geshi lang="bash">
- First I needed to compile boost. This was not so bad
$ ./configure --prefix=$HOME --exec-prefix=$HOME --with-libraries=regex --enable-static=yes
- The I had to figure out how to get source-highlight to compile
$ ./configure --prefix=$HOME --exec-prefix=$HOME --enable-static=yes --enable-shared=yes CPPFLAGS=-I${HOME}/include/boost-1_34_1 \ --with-boost-regex=gcc41-1_34_1 </geshi>
Comma separate a list
The challenge here is to avoid a trailing comma. <geshi lang="bash"> $ echo "foo\nbar\n" | awk ' {printf "%s%s",s,$0;s=","}END{print ""} ' foo,bar </geshi>
Run a command on all hosts in a netgroup
<geshi lang="bash"> mrsh -P -c 'uptime' your-netgroup </geshi>
Find all members in a sudoers group
<geshi lang="bash"> ypmatch sqladmin group </geshi>