Re: [SLUG] More spam stuff - Spamassassin and procmail

2006-10-17 Thread Rev Simon Rumble
This one time, at band camp, Scott Waller (Lots of Watts) wrote:

> Q   Do I just create the /etc/procmailrc file?  or is there a 
> better/easier way?

Normally the .procmailrc file is in the user's home directory.  So 
/home/john/.procmailrc

man procmail
man procmailrc
man procmailex

Note the -m switch on procmail.

-- 
Rev Simon Rumble <[EMAIL PROTECTED]>
www.rumble.net

The Tourist Engineer
Because geeks travel too.
http://engineer.openguides.org/

Democracy is the worst form of Government except all those
other forms that have been tried from time to time.

- Winston Churchill
-- 
SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/
Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html


[SLUG] Python problem

2006-10-17 Thread Leslie Katz
I compiled the application called gdesklets. There were complaints 
during the configuration process of my missing certain files, which I 
believed I'd overcome, since ultimately I was able to run the necessary 
installation commands with no further complaints. However, when I 
afterwards tried to open the gdesklets shell, I got the following output:


[EMAIL PROTECTED] ~]$ gdesklets shell
[EMAIL PROTECTED] ~]$ python: Objects/stringobject.c:110: 
PyString_FromString: Assertion `str != ((void *)0)' failed.


I have no idea whatever I'm being told by the above output or how to 
overcome the problem disclosed.


I'd be grateful for any advice.

Thanks,

Leslie



--
SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/
Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html


Re: [SLUG] New St George HTML based online banking interface

2006-10-17 Thread Matthew Hannigan
On Tue, Oct 17, 2006 at 04:31:08PM +1000, CaT wrote:
> On Tue, Oct 17, 2006 at 04:03:49PM +1000, Adam Kennedy wrote:
> > I can't remember EVER getting St George ones, although they've warned 
> > about them before.
> 
> You're just not popular enough with the right crowd :)
> 
>  165 N + Apr 14 St. George Bank (  77) St. George Bank Phone Verification
>  166 N   Oct 16 St. George Bank (  77) St. George Bank Phone Verification
>  167 N   Oct 17 St. George Bank (  77) St. George Bank Phone Verification
>  168 N   Oct 17 St. George Bank (  77) St. George Bank Phone Verification

You have to admit 3 is a big increase.

Ooh and hey lookie, anothery just arrived:
328 N   Oct 17 St. George Bank (   0) St. George Bank Phone Verification
-- 
SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/
Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html


Re: [SLUG] Python problem

2006-10-17 Thread Erik de Castro Lopo
Leslie Katz wrote:

> [EMAIL PROTECTED] ~]$ gdesklets shell
> [EMAIL PROTECTED] ~]$ python: Objects/stringobject.c:110: 
> PyString_FromString: Assertion `str != ((void *)0)' failed.
> 
> I have no idea whatever I'm being told by the above output or how to 
> overcome the problem disclosed.

The file Objects/stringobject.c has a bug in that it seems that
the C language layer is tring to pass a NULL C string to the
Python layer.

This is something that the person who wrote the code needs to
fix.

Erik
-- 
+---+
  Erik de Castro Lopo
+---+
"I ran it on my DeathStation 9000 and demons flew out of my nose." --Kaz
-- 
SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/
Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html


[SLUG] OSDC 2006's fabulous keynotes

2006-10-17 Thread jarich
Book before 31st October to save $50 and get a free conference t-shirt!

Registrations are open for the Open Source Developers' Conference 2006:
http://www.osdc.com.au/registration/index.html   The conference is running
in Melbourne from the 6th - 8th December, with a day of tutorials on the
5th.

Keynote talks this year include:

Damian Conway:  "The Da Vinci Codebase"

When a dying operating system scrawls his name across its corrupted boot
volume, Dr. Damian Conway, an unassuming college professor, is plunged into
a deadly race against time to solve a series of impossible riddles. What is
the mysterious "Priory of Bios?" And who are their deadly nemeses "Opus
Arai?" On the run from the law and stalked by a ghostly pale killer, will
he unravel the subtle clues hidden in Leonardo's most famous source code
and reveal to the world the incredible secret encrypted in...the Da Vinci
Codebase?


Randal L. Schwartz: "Free software - A look back, a look ahead"

A twenty year history of the free/open software movement, from my
perspective of how to contribute (in many ways!) and how to make money as
well.


Richard Farnsworth: "Open Source Synchrotron"

What is a Synchrotron anyway?  What software needs does it has?  How can
Open Source help solve these?  The Australian Synchrotron achieved first
light in July 2005 almost exclusively filling its software needs through
open source.  The code base has been refined to suit local conditions, and
shared with the rest of the Synchrotron open source community.  By sharing
information, experience and software freely between scientists and
engineers, great design efficiencies have been made further aiding the
development of experimental beamlines.


Anthony Baxter: "futurepython"

import __future__

What does the future hold for the Python language? In this talk, we'll look
at Microsoft's (Open Sourced!) IronPython and show some of the massive fun
coming down the track for scripting languages thanks to .Net and Mono.
We'll also cover Python 3.0 (now under development) and the PyPy (Python,
in Python) project.



Be a part of this fantastic conference and help it be the best developers'
conference this year!  If your business would like to benefit from exposure
to many of Australia's best open source developers then perhaps you should
consider sponsorship.  We have a wide range of sponsorship options, to find
out more information please visit:
http://www.osdc.com.au/sponsors/index.html

We look forward to sharing this great conference with you!  Don't forget to
register before 31st October to get a free conference t-shirt.

http://www.osdc.com.au/registration/index.html

Jacinta Richardson 
OSDC Publicity Officer
-- 
SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/
Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html


[SLUG] email address farming

2006-10-17 Thread Nicholas Tomlin
Hello sluggers,

No, it isn't for spamming...

I've changed my email address again and wish to send emails out to anyone who 
has sent one to me, short of individually collecting them and putting them 
into my kontact data base is there a way of farming them to collect them all 
and throw out the ones I don't want?

All the messages are in kmail and there are about 1600 of them, so individual 
collection would be a large PITA.

Any ideas would be appreciated.

TIA,

Nicholas Tomlin.
-- 
SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/
Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html


Re: [SLUG] More spam stuff - Spamassassin and procmail

2006-10-17 Thread Sonia Hamilton
* On Tue, Oct 17, 2006 at 08:02:01AM +0100, Rev Simon Rumble wrote:
> This one time, at band camp, Scott Waller (Lots of Watts) wrote:
> 
> > Q   Do I just create the /etc/procmailrc file?  or is there a 
> > better/easier way?
> 
> Normally the .procmailrc file is in the user's home directory.  So 
> /home/john/.procmailrc
> 
> man procmail
> man procmailrc
> man procmailex
> 
> Note the -m switch on procmail.

You'll probably find the procmail pages a bit obscure; there's lots
of web guides out there.

My favourite is by Prof Timo Salmi, 
http://lipas.uwasa.fi/~ts/info/proctips.html, especially
"Building a Testbench".

--
Sonia Hamilton. GPG key A8B77238.
.
One OS to rule them all, One OS to find them.
One OS to call them all, And in salvation bind them.
In the bright land of Linux, Where the hackers play. 
-- 
SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/
Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html


[SLUG] rebooting a non scrolling mouse

2006-10-17 Thread david


I switch between two systems using a Belkin KVM, and when I return to
Dapper, the mouse no longer scrolls. After a little while if I'm lucky
it will start to scroll again. I can't pick a pattern though.

I've tried waiting after KVM switching (previously suggested by someone)
but no luck.

Any suggestions about forcing the system to re-read the mouse in some
way? Perhaps something equivalent to #/etc/init.d/gpm restart

thanks...
David.

-- 
SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/
Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html


[SLUG] suse

2006-10-17 Thread Joachim Herrmann

Hi slugs,
I am in the process of (hopefully) converting our school from winxp to 
Novell and suse.  Found out about you at the Moodle conference; - can 
you help with advice about useful apps?  We need a good Flash editor, 
website design, CAD program, - things schools need. 
  My school phone and email are 4757 2253

   [EMAIL PROTECTED]
   Regards,   Joachim
begin:vcard
fn:Joachim Herrmann
n:Herrmann;Joachim
org:Livspace
adr;dom:;;6 West Street;Leura;NSW;2780
email;internet:[EMAIL PROTECTED]
tel;work:02 4784 3734
x-mozilla-html:TRUE
url:http://www.livspace.com.au
version:2.1
end:vcard

-- 
SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/
Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html

Re: [SLUG] suse

2006-10-17 Thread Simon Males

Hello Joachim!

	Great to hear that your trying to migrate your school to Linux. Now 
about the applications you require:


Flash Editor
There's tool called Flash for Linux[1], but it's still in development 
and from what I can see development has halted (thus not all that good 
in your case). Personally I'm against encouraging school children to use 
it due to it's heavy proprietary nature. A good and _complex_ animation 
package is Blender[2]. Although not embeddable into websites, if that is 
your intention.


Website design.
Nvu[3], the website is pretty informative about it's features.

CAD
Qcad[4], simple CAD program.

You'll find a number of sluggers have or do work with schools as well, 
so your not alone!


[1] http://f4l.sourceforge.net/
[2] http://blender.org/
[3] http://nvu.com/index.php
[4] http://www.ribbonsoft.com/qcad.html

Note that all of the above software is available on Linux and Windows, 
so students can use them freely at home.


--
Simon Males <[EMAIL PROTECTED]>


Joachim Herrmann wrote:

Hi slugs,
I am in the process of (hopefully) converting our school from winxp to 
Novell and suse.  Found out about you at the Moodle conference; - can 
you help with advice about useful apps?  We need a good Flash editor, 
website design, CAD program, - things schools need.   My school 
phone and email are 4757 2253

   [EMAIL PROTECTED]
   Regards,   Joachim


--
SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/
Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html


Re: [SLUG] suse

2006-10-17 Thread Erik de Castro Lopo
Joachim Herrmann wrote:

> We need a good Flash editor, 

Joachim, 

I do quite a bit of messing about with Flash in my day job
and I can assure you that there is nothing like the Macromedia
Flash development tools on Linux. Even the Free Software Flash
player, Gnash ( http://www.gnu.org/software/gnash/ ) is nowhere
near ready for general use.

Flash is a closed proprietary product which is bandwidth intensive
in comparison to other web formats, it breaks the operation of the
back/forward buttons on web browsers etc.

My advice is to steer people away from developing web sites with
Flash and instead concentrate on widely used, truely open web 
standards.

Hope this helps,
Erik
-- 
+---+
  Erik de Castro Lopo
+---+
A Microsoft Certified System Engineer is to computing what a
MacDonalds Certified Food Specialist is to fine cuisine.
-- 
SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/
Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html


[SLUG] Google women in engineering event

2006-10-17 Thread Pia Waugh
Hi all,

Google are putting on a free evening for women in engineering. Come along to
meet some awesome local women in IT, hear from Jen Fitzpatrick and Rob Pike
from Google, get some free Google schwag and enjoy some yummy food and
drinks.

Thursday, October 26th
6:30pm - 10:00pm

http://services.google.com/events/ohsydney_rsvp

Rock! Hope to see you all there :)

Cheers,
Pia

-- 
Linux Australia http://linux.org.au/
 
  "What are we doing today brain?"
  "We're taking over the world like we always do."
   - Pinky and the Brain
-- 
SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/
Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html


[SLUG] Python problem

2006-10-17 Thread Leslie Katz
Thanks very much for the reply, Erik. I'll now try to contact the 
developers.


Leslie
--
SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/
Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html


Re: [SLUG] email address farming

2006-10-17 Thread James Gray

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On 17/10/2006, at 6:52 PM, Nicholas Tomlin wrote:


No, it isn't for spamming...

I've changed my email address again and wish to send emails out to  
anyone who
has sent one to me, short of individually collecting them and  
putting them
into my kontact data base is there a way of farming them to collect  
them all

and throw out the ones I don't want?

All the messages are in kmail and there are about 1600 of them, so  
individual

collection would be a large PITA.


If your mail is stored locally on your PC, then you could simply  
write a script to rip through your mail store and grab all unique  
"From" headers and dump them into a file.  Edit the file at your  
leisure, then use it to pump out the new messages :)


Shouldn't take more than about 10 minutes.  Of course, if your  
scripting is a little rusty, it might take longer :P


Cheers,

James
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.3 (Darwin)

iD8DBQFFNVGmwBHpdJO7b9ERAma6AJ9EhSSJslwQFgLi86evOulOT6IxywCgv6Uu
xrcRvVqoNbmLYfUXvF9mhas=
=Hq1K
-END PGP SIGNATURE-
--
SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/
Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html


Re: [SLUG] rebooting a non scrolling mouse

2006-10-17 Thread Scott Ragen
[EMAIL PROTECTED] wrote on 17/10/2006 08:38:14 PM:

> 
> 
> I switch between two systems using a Belkin KVM, and when I return to
> Dapper, the mouse no longer scrolls. After a little while if I'm lucky
> it will start to scroll again. I can't pick a pattern though.
> 
> I've tried waiting after KVM switching (previously suggested by someone)
> but no luck.
> 
> Any suggestions about forcing the system to re-read the mouse in some
> way? Perhaps something equivalent to #/etc/init.d/gpm restart
> 
Do you have any objections to using gpm in X?
you could try modifying your pointer section in your xorg.conf as such:
Device "/dev/gpmdata"

Restarting gpm as you mentioned might reset it.

Alternatively, if its a usb mouse, you could just unplug and re-plug it in 
each time.
If its a serial mouse, check out:
http://www.faqs.org/docs/Linux-mini/3-Button-Mouse.html#s6

Cheers,

Scott


-- 
SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/
Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html


[SLUG] Script not working

2006-10-17 Thread Kazik Malenczak
I have a script to backup a VMWare virtual machine which when run manually 
on the box by root runs OK, but when run by cron...well, it doesn't.


This is the script 

echo VMSNAP Backup Script
echo _
rm -f /vmimages/localbackup/###-###-REP1/*
rm -f /vmimages/localbackup/###-###-VDB1/*
echo Old images erased, new backup started
date
/usr/sbin/vmsnap_all
echo Backup complete, copy started
date
scp -r /vmimages/localbackup/* 192.168.0.1:/vmimages/from_vm1
echo Copy complete, script exiting
date



/var/log/messages   shows

Oct 15 16:30:05 RKI-SYD-VM1 sshd(pam_unix)[5470]: session opened for user 
root by (uid=0)
Oct 15 16:30:05 RKI-SYD-VM1 sshd(pam_unix)[5470]: session closed for user 
root
Oct 15 16:30:12 RKI-SYD-VM1 sshd(pam_unix)[5533]: session opened for user 
root by (uid=0)
Oct 15 16:30:12 RKI-SYD-VM1 sshd(pam_unix)[5533]: session closed for user 
root
Oct 15 16:30:17 RKI-SYD-VM1 sshd(pam_unix)[5549]: session opened for user 
root by (uid=0)


The script is set to run at 4:30pm

/var/log/cron shows it starting ...

Oct 17 16:30:00 RKI-SYD-VM1 CROND[16132]: (root) CMD (/root/vm1_snap.sh  
#Daily vmsnap backup script)


There is nothing in /etc/pam.d/cron


Could someone please tell me why it may not be working. Why does it say 
about an ssh session opening? I think it may be a pam issue but my skills 
are a bit patchy with how cron,pam and ssh all work together.


Thanks

Kaz


--
SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/
Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html


Re: [SLUG] suse

2006-10-17 Thread jam
On Wednesday 18 October 2006 01:29, [EMAIL PROTECTED] wrote:
> Hi slugs,
> I am in the process of (hopefully) converting our school from winxp to
> Novell and suse.  Found out about you at the Moodle conference; - can
> you help with advice about useful apps?  We need a good Flash editor,
> website design, CAD program, - things schools need.
>        My school phone and email are 4757 2253
>                 [EMAIL PROTECTED]
>                                                     Regards,   Joachim
> Attached business cards
>   Joachim Herrmann
>   Livspace
>       
>   Work  02 4784 3734
>   Email  [EMAIL PROTECTED]
>   Homepage  http://www.livspace.com.au
>   Domestic  6 West Street
> Leura NSW, 2780
> [Add this contact to the addressbook]
>
>
>   End of encapsulated message

Have you looked at ltsp? http://www.ltsp.org
James
--
SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/
Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html


Re: [SLUG] dual monitor video card

2006-10-17 Thread Steve Kowalik
On Tue, 17 Oct 2006 14:46:58 +1000, Ben uttered
> doh! I meant PCIe, but that's probably what you mean anyway. and it
> was just last week I was scoping hardware sites and laughing at the
> ones who labelled the PCIe cards PCIx.
> 
PCI-X and PCI-E are very different.

http://en.wikipedia.org/wiki/PCI-X

and

http://en.wikipedia.org/wiki/PCI_Express

Cheers,
-- 
Steve
In the beginning was the word, and the word was content-type: text/plain
-- 
SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/
Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html


Re: [SLUG] Script not working

2006-10-17 Thread Scott Ragen
[EMAIL PROTECTED] wrote on 18/10/2006 10:16:14 AM:

> I have a script to backup a VMWare virtual machine which when run 
manually 
> on the box by root runs OK, but when run by cron...well, it doesn't.
> 
> This is the script 
> 
> echo VMSNAP Backup Script
> echo _
> rm -f /vmimages/localbackup/###-###-REP1/*
> rm -f /vmimages/localbackup/###-###-VDB1/*
> echo Old images erased, new backup started
> date
> /usr/sbin/vmsnap_all
> echo Backup complete, copy started
> date
> scp -r /vmimages/localbackup/* 192.168.0.1:/vmimages/from_vm1
> echo Copy complete, script exiting
> date
> 
> 
> 
> /var/log/messages   shows
> 
> Oct 15 16:30:05 RKI-SYD-VM1 sshd(pam_unix)[5470]: session opened for 
user 
> root by (uid=0)
> Oct 15 16:30:05 RKI-SYD-VM1 sshd(pam_unix)[5470]: session closed for 
user 
> root

As far as I know, this states a session was successful via ssh (scp), 
perhaps there is nothing to place on the remote box? (eg, 
/usr/sbin/vmsnap_all didn't work)
What is /usr/sbin/vmsnap_all, is it a shell script? Perhaps it relies on 
environment variables that are not set in the cron.
After it is run from the cron, do the backups exist on the local machine's 
/vminages/localbackup?

Cheers,

Scott

-- 
SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/
Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html


Re: [SLUG] Script not working

2006-10-17 Thread Martin Barry
$quoted_author = "Kazik Malenczak" ;
> 
> I have a script to backup a VMWare virtual machine which when run manually 
> on the box by root runs OK, but when run by cron...well, it doesn't.

it's probably a path issue.

log the cron output somewhere and check the error.


> Could someone please tell me why it may not be working. Why does it say 
> about an ssh session opening? I think it may be a pam issue but my skills 
> are a bit patchy with how cron,pam and ssh all work together.

scp uses ssh which is using pam for authentication.

cheers
marty

-- 
"its a mailing list... its only slightly better than a web forum.
 the main improvement is that no one has anime-p0rn avatars. Dean" [1]

[1] - http://lists.slug.org.au/archives/slug/2005/12/msg00309.html`
-- 
SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/
Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html


[SLUG] Malone Question

2006-10-17 Thread James Dumay
Hey guys,When I have subscribed to a bug in Launchpad.net's Malone bug tracker and the bug gets marked as a duplicate, does it automatically subscribe me to the other bug report?
Cheers,~James
-- 
SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/
Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html

Re: [SLUG] suse

2006-10-17 Thread James Dumay
Also OpenLaszlo is an opensource Flash like technologyhttp://www.openlaszlo.org/JamesOn 10/17/06, 
Erik de Castro Lopo <[EMAIL PROTECTED]> wrote:
Joachim Herrmann wrote:> We need a good Flash editor,Joachim,I do quite a bit of messing about with Flash in my day joband I can assure you that there is nothing like the MacromediaFlash development tools on Linux. Even the Free Software Flash
player, Gnash ( http://www.gnu.org/software/gnash/ ) is nowherenear ready for general use.Flash is a closed proprietary product which is bandwidth intensive
in comparison to other web formats, it breaks the operation of theback/forward buttons on web browsers etc.My advice is to steer people away from developing web sites withFlash and instead concentrate on widely used, truely open web
standards.Hope this helps,Erik--+---+  Erik de Castro Lopo+---+A Microsoft Certified System Engineer is to computing what a
MacDonalds Certified Food Specialist is to fine cuisine.--SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/Subscription info and FAQs: 
http://slug.org.au/faq/mailinglists.html
-- 
SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/
Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html

Re: [SLUG] Script not working

2006-10-17 Thread jam
On Wednesday 18 October 2006 10:00, [EMAIL PROTECTED] wrote:
> I have a script to backup a VMWare virtual machine which when run manually
> on the box by root runs OK, but when run by cron...well, it doesn't.
>
> This is the script 
>
> echo VMSNAP Backup Script
> echo _
> rm -f /vmimages/localbackup/###-###-REP1/*
> rm -f /vmimages/localbackup/###-###-VDB1/*
> echo Old images erased, new backup started
> date
> /usr/sbin/vmsnap_all
> echo Backup complete, copy started
> date
> scp -r /vmimages/localbackup/* 192.168.0.1:/vmimages/from_vm1
> echo Copy complete, script exiting
> date
>
>
>
> /var/log/messages   shows
>
> Oct 15 16:30:05 RKI-SYD-VM1 sshd(pam_unix)[5470]: session opened for user
> root by (uid=0)
> Oct 15 16:30:05 RKI-SYD-VM1 sshd(pam_unix)[5470]: session closed for user
> root
> Oct 15 16:30:12 RKI-SYD-VM1 sshd(pam_unix)[5533]: session opened for user
> root by (uid=0)
> Oct 15 16:30:12 RKI-SYD-VM1 sshd(pam_unix)[5533]: session closed for user
> root
> Oct 15 16:30:17 RKI-SYD-VM1 sshd(pam_unix)[5549]: session opened for user
> root by (uid=0)
>
> The script is set to run at 4:30pm
>
> /var/log/cron shows it starting ...
>
> Oct 17 16:30:00 RKI-SYD-VM1 CROND[16132]: (root) CMD (/root/vm1_snap.sh  
> #Daily vmsnap backup script)
>
> There is nothing in /etc/pam.d/cron
>
>
> Could someone please tell me why it may not be working. Why does it say
> about an ssh session opening? I think it may be a pam issue but my skills
> are a bit patchy with how cron,pam and ssh all work together.


Um how about step by step:
Can root on machineA ssh to machineB without password?
If NO then on machineA do ssh-keygen -t rsa (as root)
copy id_rsa.pub to .ssh/authorized_keys (sic) on machineB (also using ~root)

Now you ought to be able to ssh to machineB without password
Now the backup should run

James
--
SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/
Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html


Re: [SLUG] scripting question

2006-10-17 Thread Daniel Bush

Hi

On 17/10/06, Sonia Hamilton <[EMAIL PROTECTED]> wrote:

I've written a small script that archives email - it works, but I was
wondering if there's any better way to write it (apart from using
another language).

Damn.


The script is:

> for i in z_bak:7 root:14 y_spam_definite:56 ; do
> mydir=${i%:*}
> mydays=${i#*:}

$mydir is the directory to cleanup, $mydays is the # of days I want to
keep email. Is there any better way of writing the for loop to go thru
the 2 sets of values?


Not that I can see - mildly curious to know if there is.  AFAIK Bash
only has 1-dimensional arrays (in my version), certainly no hashes.
The above script looks quite compact along with those annoying
substitution operators that I can never remember.

I tend to use 'case' if I'm shelling - which is far more verbose:

for mydir in z_bak root y_spam_definite ; do
 case $mydir in
   z_bak)
 mydays=7
   ;;
   foo|bar|baz)
 mydays=100
   ;;
   *)
  echo "$0: Bad mail directory used : '$mydir'" >&2
   ;;
 esac
done



Here is a crazy version using arrays:

expires=(
z_bak:7
root:14
y_spam_definite:56
)

for (( i=0; i<${#expires[*]}; i++ )); do
 j=${expires[$i]}
 mydir=${j%:*}
 mydays=${j#*:}
done

It's kinda lost some clarity at this point (!).  What I was trying to
do was to put the delete settings at the top in a simple list for easy
configuration.
(I've used arrays before in a script which stores my sometimes
numerous working directories in a file so that I can call these up and
jump back and forth between locations more easily)

Daniel.
--
SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/
Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html


Re: [SLUG] scripting question

2006-10-17 Thread Martin Pool
On 17 Oct 2006, Sonia Hamilton <[EMAIL PROTECTED]> wrote:
> I've written a small script that archives email - it works, but I was
> wondering if there's any better way to write it (apart from using
> another language).
> 
> The script is:
> 
> > for i in z_bak:7 root:14 y_spam_definite:56 ; do
> > mydir=${i%:*}
> > mydays=${i#*:}
> 
> $mydir is the directory to cleanup, $mydays is the # of days I want to
> keep email. Is there any better way of writing the for loop to go thru
> the 2 sets of values?

Using associative arrays in zsh (or ksh or maybe bash?) you can write

 typeset -A to_archive
 to_archive=(z_bak 7 root 14 y_spam_definite 56)
 for mydir in ${(k)to_archive}
 do 
   mydays=$to_archive[$mydir]

But I've actually never used them before doing this, and I have to say
the ${(k)to_archive} is beyond my current tolerance for shell wierdness.

-- 
Martin
-- 
SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/
Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html