For Programmers: Free Programming Magazines  


Home > Archive > PERL Beginners > June 2007 > Beginner needs help









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Beginner needs help
Rick

2007-06-28, 3:59 am

Ok so the boss wants me to create two scripts in perl and I don't even
know where to begin.



One is to copy a log file to a backup server every hour.



And the second is to restore the backup from one server from the
previous night to the backup server every morning.



Any ideas on where to start would be greatly appreciated.



Thanks

Rick

Chas Owens

2007-06-28, 3:59 am

On 6/27/07, Rick <rbw940@yahoo.com> wrote:
> Ok so the boss wants me to create two scripts in perl and I don't even
> know where to begin.
>
> One is to copy a log file to a backup server every hour.
>
> And the second is to restore the backup from one server from the
> previous night to the backup server every morning.
>
> Any ideas on where to start would be greatly appreciated.

snip

A lot depends on your knowledge of Perl. Given that you have no idea
where to begin I assume you know nothing. Run out and buy Learning
Perl. Read the first few chapters and then take a look at Net::FTP*
or Net::SCP*. If you still have questions how things work then post
them with the code you are trying to make work to the list.

* http://search.cpan.org/~gbarr/libnet-1.21/Net/FTP.pm
* http://search.cpan.org/~ivan/Net-SCP-0.07/SCP.pm
Ricky Zhou

2007-06-28, 3:59 am

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Rick wrote:
> Ok so the boss wants me to create two scripts in perl and I don't even
> know where to begin.
>
>
>
> One is to copy a log file to a backup server every hour.
>
>
>
> And the second is to restore the backup from one server from the
> previous night to the backup server every morning.
>
>
>
> Any ideas on where to start would be greatly appreciated.

To be honest, this really sounds like the jobs for a cronjob and a shell
script, at most. Are you sure that you even need Perl for this?

Hope this helps,
Ricky
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (GNU/Linux)

iD8DBQFGgt6mZBKKLMyvSE4RAr8eAJ4xW+TozSc4
uoXgAEVaBRjBQ1oZygCgs+bH
sbSetfvIvL5cgtJkYKhT4QA=
=P48d
-----END PGP SIGNATURE-----
Chas Owens

2007-06-28, 3:59 am

On 6/27/07, Chas Owens <chas.owens@gmail.com> wrote:
> On 6/27/07, Rick <rbw940@yahoo.com> wrote:
> snip
>
> A lot depends on your knowledge of Perl. Given that you have no idea
> where to begin I assume you know nothing. Run out and buy Learning
> Perl. Read the first few chapters and then take a look at Net::FTP*
> or Net::SCP*. If you still have questions how things work then post
> them with the code you are trying to make work to the list.
>
> * http://search.cpan.org/~gbarr/libnet-1.21/Net/FTP.pm
> * http://search.cpan.org/~ivan/Net-SCP-0.07/SCP.pm
>



Specifically chapters 2 Scalar Data, 4 Subroutines, 6 I/O Basics, and
11 Filehandles and File Tests.
Abadedmoha2

2007-06-29, 6:33 pm

Christina Applegate Is Hot And Sex...!

http://www.thetubetech.com/Watch?movie=726071
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com