Giter Site home page Giter Site logo

rexops / rex Goto Github PK

View Code? Open in Web Editor NEW
703.0 62.0 222.0 8.55 MB

Rex, the friendly automation framework

Home Page: https://www.rexify.org

Perl 99.19% Shell 0.73% Smarty 0.01% Elixir 0.01% REXX 0.01% Roff 0.01% Euphoria 0.06%
rex infrastructure-as-code infrastructure-automation automation framework perl devops configuration-management rexops

rex's People

Contributors

abeverley avatar ajaxhelios avatar alip avatar andrejzverev avatar aowi avatar bokutin avatar chenryn avatar chorny avatar choroba avatar cpanxaoc avatar ehuelsmann avatar eskaaren avatar ferki avatar hnakamur avatar jmrenouard avatar jorisd avatar jwbargsten avatar kablamo avatar mbroadhead avatar protocall7 avatar reneeb avatar roa avatar samuelet avatar sasg avatar sbertrang avatar sdondley avatar svendowideit avatar symacx avatar timp87 avatar uralm1 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

rex's Issues

Suppress SSH error output

Is it possible to suppress error message output generated by SSH? For example, when the user directory is not on the target server, I get a "Could not chdir to home directory /home/users/myusername: No such file or directory" error. I need this to be suppressed when generating reports.

sudo commands fail when requiretty is enabled

When requiretty is enabled on a remote server, sudo commands fail with the following error message:

"sorry, you must have a tty to run sudo"

I can't disable the remote server configuration. So is it possible to signal the Net::SSH2 library to use the pty() call?

uninitialized value

Version 0.31:

While executing a task (pass_key auth), commands throw the warning :

Use of uninitialized value $host in substitution (s///) at /usr/local/share/perl/5.10.1/Rex/Logger.pm line 216

Changing the host check into Rex::get_current_connection()->{server} fixes it.

before keyword

I've discovered a pain point

I've put some tasks into some perl modules, so rex -T has tasks like Assembly:create - you can't add a 'before' statement to it by that name.. I can run it that way tho - can't put a 'before' to Assembly::create either..

Newlines on Windows

When using Rex on Windows it doesn't always convert the newlines which causes the Windows terminal to append all lines from the output. I think it should convert \n to \r\n to make it properly display the output to the terminal.

For example, running say run "free -m" displays fine in the terminal (aside from the big sized tabs, but I don't consider that a Rex issue). But when running a say run "ls -al" newlines don't seem to get converted.

Wrong option handling in mount with persistent feature

The persistent option of mount does not properly handle mount options, when it writes to /etc/fstab.

See line 665 in /usr/share/perl5/Rex/Commands/Fs.pm. It should de-serialize the option array, but it does not in V33.3

Consider:
my $mountops = join(",", @{$option->{"options"}});
push(@new_content, "$device\t$mount_point\t$option->{fs}\n$mountops\t0 0\n");

instead of
push(@new_content, "$device\t$mount_point\t$option->{fs}\n$option->{options}\t0 0\n");

checking for $1

Hi,

if we call "rex" without any parameters, it would be great, if we get the help output (rex -h).

Cheers,

Matthias

add a some config files for rex

initially, I'm using ~/.rex/RexConfig.pm, and then was going to store other things in that dir too, but it might also make sense to use the Perl module preferences to store system wide prefs.

Function arguments

After upgrading to the latest version, some of my scripts stopped working. It looks like the old way of passing arguments is not working any more.

Old way does not work:

my $rpmDir = 'rpmDir'
MyModule::RpmInternal::_download($rpmDir);

task _download => sub {
    my ($rpmDir) = @_;
    say("Downloading results to local directory at $rpmDir.");
    sync($remoteDir . "/*", $rpmDir . "/", {
      download => 1,
    });
};

New method to get the script working again:

my $rpmDir = 'rpmDir'
my %params = (
    'rpmDir' => $rpmDir
);

MyModule::RpmInternal::_download(%params);

task _download => sub {
    my ($params) = @_;
    my $rpmDir = $params->{'rpmDir'};
    say("Downloading results to local directory at $rpmDir.");
    sync($remoteDir . "/*", $rpmDir . "/", {
      download => 1,
    });
};

Is this by design? Or is this a bug?

Lvdisplay wrong option in debian squeeze

The Rex lvm command does not work in debian squeeze because the lv_path value (lvdisplay command in the line 166 of /usr/share/perl5/Rex/Commands/LVM.pm) not exist in the lvm command of this distribution.

Installing packages as sudo

How to write a task to do that. I tried something like this ...

use Rex::Commands::Pkg

user 'user';
private_key 'key';
public_key 'public';
key_auth;

desc 'install git';
task 'install-git', sub {
   install package => 'git'
};

I am connecting with user who has sudo access. However, the above task invokes

yum -y install git

which obviously do not work without sudo.

Invoking run 'sudo yum -y install git' is an option, but i am tried to avoid os specific command if possible.

ssh with kerberos auth?

My linux server group all authenticated by kerberos. When I run rex command, I received message ‘Wrong username or password. Or wrong key’.
I run a Net::SSH2 script and get the authlist of method 'gssapi-keyex' and 'gssapi-with-mic'.But they all donot be supportted by auth().
Which module can support gssapi auth method? And can I replace that module into Rex?

Rex::Commands::Iptables iptables_list wrongly parses iptables-save line

my @parts = grep { ! /^\s+$/ && ! /^$/ } split (/(\-\-?[^\s]+\s[^\s]+)/i, $line);

does not yield correct reusults on rules like:

-A syn_flood -p tcp -m tcp --tcp-flags FIN,SYN,RST,ACK SYN -m limit --limit 25/sec --limit-burst 50 -j RETURN

This would later on be intepreted as an key ' ' with value 'SYN', which is clearly not intended.

I've toyed around with it a bit and found this split quite useful:

my @parts = grep { ! /^\s+$/ && ! /^$/ } split (/^\-\-?|\s+\-\-?/i, $line); 

by the way, this renders the following obsolete:

$key =~ s/^\-+//;

since I did not include the separator.

Kind regards
Dominik

[warn] no Scope::With found

Hi,

if I do e.g "rex -v" I always get

[warn] no Scope::With found

Do I really need these module?

Cheers,

Matthias

Commands run return strings without "\n"?

If I use rex -e 'say run "ls"', I will see output like:

anaconda-ks.cfgglbc1.l.xiaonei.com.initinstall.loginstall.log.syslogrubygems-1.8.24rubygems-1.8.24.tgzrvm-installer

Need to use rex -e 'say $_ for run "ls"' or rex -e 'run "ls", sub { say shift }' to see output like:
anaconda-ks.cfg
install.log
install.log.syslog
rubygems-1.8.24
rubygems-1.8.24.tgz
rvm-installer

I check run sub in lib/Rex/Commands/Run.pm but found nothing seem to be wrong. Any help?

Async Support

I'm wondering if Async support is something that is on the roadmap for this project. If I need to run a command on 15 servers, it would be great to have the option to run them all at once, rather than one at a time sequentially.

on_change is always executed

Anytime i execute a task which uploads a file, the on_change hook is executed regardless the fact that the local and remote files are the same.
Am i missing something or is it a bug?

Debian Squeeze with rex 0.26.2 deb:

Rexfile:
.....
file "/etc/default/ntpdate",
source => "/root/rexfiles/ntpdate_ntp1.conf",
mode => 644,
on_change => sub { say "File was changed."; };
....

Log:

2012-04-25 22:46:41 DEBUG - Executing prepare
2012-04-25 22:46:41 - INFO - Uploadling /root/rexfiles/ntpdate_ntp1.conf -> /etc/default/ntpdate
2012-04-25 22:46:41 DEBUG - Executing: chmod 644 /etc/default/ntpdate
2012-04-25 22:46:41 DEBUG -
2012-04-25 22:46:41 DEBUG - File /etc/default/ntpdate has been changed... Running on_change
2012-04-25 22:46:41 DEBUG - old:
2012-04-25 22:46:41 DEBUG - new:
File was changed.
2012-04-25 22:46:41 DEBUG - Disconnecting from webmail3
2012-04-25 22:46:41 DEBUG - Connections in queue: 0
2012-04-25 22:46:42 DEBUG - Removing lockfile

Better Error Messages

Rex could use some better error messages, especially when requiring other packages/files.

I had some trouble debugging a Rexfile that was showing me no tasks because the required files had deps that weren't installed on my system. Even running rex -d -T didn't tell me anything. I had to tell Rex to run the required files directly to get any useful errors.

Request - Private IP on Cloud List (With Snippit)

Firstly, simply amazing resource. I use it on all of my deployments, so thank you for your time, it has saved me a lot.

Quick request - most of my deployments employ the use of SSH tunnels in order to secure instances from the outside world. It's a pretty common practice, as I'm sure you are aware. I have a task that creates an instance, then uses the instances internal IP to connect and continue the task, leading to a newly programmed server within seconds; really powerful stuff.

I believe the majority of users would benefit from adding the private-ip to the cloud offering. Rather than doing a pull request, I felt it would be better to include the edit here, since it was just one line.

Edit:
lib/Rex/Cloud/Amazon.pm:256
Add:
priv_ip => $instance_set->{"instancesSet"}->{"item"}->{"private-ip-address"},

Thanks for the consideration, and again, fantastic resource, bravo.

HOME env. variable error - Rex 0.21 on Windows

Hi,
I got the following error with Rex 0.21 on Windows.

>rex
Use of uninitialized value $ENV{"HOME"} in concatenation (.) or string at C:/strawberry-perl-5.12.3.0-portable/perl/site/lib/Rex/Config.pm line 130.
Use of uninitialized value $ENV{"HOME"} in concatenation (.) or string at C:/strawberry-perl-5.12.3.0-portable/perl/site/lib/Rex/Config.pm line 117.
Use of uninitialized value $ENV{"HOME"} in concatenation (.) or string at C:/strawberry-perl-5.12.3.0-portable/perl/site/lib/Rex/Config.pm line 130.
.
.
.

Need http://search.cpan.org/perldoc?File::HomeDir module ?

Show groups in rex -T output

Hi!
Thanks for this cool tool )
When more then one man use rex, often someone forget names of server groups.
It would be very nice if rex will print all group names to rex -T output.

Way to get the current environment

Is there a way to get the name of the current environment in my Rexfile scripts?

I couldn't find a way to do this, but if it is there, it should probably be added to the documentation ( I don't mind doing this once I figure out how to do it :) )

Proxy support

Was wondering would it possible to have proxy support in the Rexfile? I have to go through a proxy to install updates and packages. Thanks

关于分区部分的bug

rex bug

*1

157
158 # get the partition id
159 my @Partitions = grep { /$disk\d+$/ } split /\n/, cat "/proc/partitions";
160 my ($part_num) = ($partitions[-1] =~ m/^\s+\d+\s+(\d+)\s+/);
161
162 print "$part_num\n";
163 exit;

这个取值有问题

8 17 927734784 sdb1

修改为
160 my ($part_num) = ($partitions[-1] =~ m/sd\w+(\d+)/);

*2

184 while(! -e "/dev/$disk$part_num") {
185 Rex::Logger::debug("Waiting on /dev/$disk$part_num to appear...");
186 sleep 1;
187 }

这个会一直卡着 我发现这个代码是错误的。。只是检查本机的那个磁盘设备,如果本地没有那个磁盘就一直等待在这里

*3

204 if(exists $option{mount} && $option{mount}) {
205 run "xfs.admin -L $option{lable} $disk$part_num";
206 #mount "$disk$part_num", $mountpoint,
207 # fs => $option{fstype};
208 run "echo "LABEL=$option{lable} $mountpoint xfs defaults,noatime,nobarrier 0 0" >> /etc/fstab";
209 run "mount -a";

修改自动挂载功能 将标签写入到fstab 每次用mount -a 挂载

rex 中的变量很多不能用如auth

Environment does not override ssh auth

I need to use ssh keys as default connection but override it with pass_auth for some hosts.
Unfortunately this does not work:

public_key "/root/.ssh/key.pub";
private_key "/root/.ssh/key";

desc "uptime";
task "uptime","www.example.com", sub {
  say run "uptime";
};

environment ask_pass => sub {
    password "password: ";
    pass_auth;
}
# rex -d -E ask_pass test

server: www.example.com
[2012-05-05 12:09:07] <local> - Using user: root
[2012-05-05 12:09:07] <local> - Using password: <no password>
[2012-05-05 12:09:07] <local> - My Hostname: localhost
[2012-05-05 12:09:07] <local> - My Shortname: localhost
[2012-05-05 12:09:07] <local> - Next Server: www.example.com
[2012-05-05 12:09:07] <local> - Waiting for children to finish
[2012-05-05 12:09:07] <local> - Connecting to www.example.com:22 (root)
[2012-05-05 12:09:07] <local> - Current Error-Code: -37
[2012-05-05 12:09:07] <local> - Connected to www.example.com, trying to authenticate.
[2012-05-05 12:09:07] www.example.com - Wrong username or password. Or wrong key.
[2012-05-05 12:09:07] <local> - Removing lockfile

User Parameter not used

If there is a user specified within the Rexfile there is no posibility to change the user by command line switch "-u"

Using environments

I'm having a slight issue with environments. I've different groups setup. One for web, one for storage and one for databases. My question would be. Is this the intended behaviour? Thanks

group "web" => "host01";
group "storage" => "host02", "host03";
group "database" = > "host04", "host05";

environment web => sub {
group "web" => "host01";
};

rex -E web tasks:uptime

2012-03-26 11:25:16 - INFO - Running task: task:uptime
2012-03-26 11:25:16 - INFO - Connecting to host02:22 (user)
2012-03-26 11:25:17 - INFO - Connected to host02, trying to authenticate.
11:25:08 up 9 days, 16:42, 1 user, load average: 0.00, 0.08, 0.12
2012-03-26 11:25:21 - INFO - Connecting to host03:22 (user)
2012-03-26 11:25:22 - INFO - Connected to host03, trying to authenticate.
11:25:15 up 9 days, 16:42, 1 user, load average: 0.00, 0.08, 0.12

inconsistent feel to Command locality

I started to think that rex commands are 'run' on the remote host.

until I used 'sync' which is not.

can this be made consistent?

(the reason was that i need to sync data from several hosts to the newly created vm - so rather than doing:

sync 'sven@quad:/data/home/sven/src/distributedinformation/projects/Perl/FoswikiInstaller/Packages/*', 'foswiki/Packages/';

I've had to resort to:

run 'rsync -av sven@quad:/data/home/sven/src/distributedinformation/projects/Perl/FoswikiInstaller/Packages/* foswiki/Packages/';

I find the 'run' remote execution of checkout, install and sysctl to be convenient, but it is a bit misleading, as there's no indication for a new reader telling them that some code is local and other code is not.

-G and -e cli options

The -G option is discarded when used togheter with -e .
For example:
rex -G "mygroup" -e "say run 'hostname'"

will be executed on localhost.

Error -37 when using SSH Public-Key authentication with ssh-agent

Hi

I setup passphrase protected ssh public key login with ssh-agent to serveral servers. When I try to run a command via Rex I get a Error -37.

Without digging into the sources too much, is this supposed to work or is there still some implementation needed?

ganto@merkur ~ $ rex -e 'say run "uptime";' -d -H "centos6 funtoo" -P ~/.ssh/id_admin_rsa -K ~/.ssh/id_admin_rsa.pub 
[2011-09-06 21:36:09] (8063) DEBUG - Command Line Parameters
[2011-09-06 21:36:09] (8063) DEBUG -    H = centos6 funtoo
[2011-09-06 21:36:09] (8063) DEBUG -    e = say run "uptime";
[2011-09-06 21:36:09] (8063) DEBUG -    u = root
[2011-09-06 21:36:09] (8063) DEBUG -    K = /home/ganto/.ssh/id_admin_rsa.pub
[2011-09-06 21:36:09] (8063) DEBUG -    P = /home/ganto/.ssh/id_admin_rsa
[2011-09-06 21:36:09] (8063) DEBUG -    d = 1
[2011-09-06 21:36:09] (8063) DEBUG - Executing command line code
[2011-09-06 21:36:09] (8063) DEBUG -    say run "uptime";
[2011-09-06 21:36:09] (8063) DEBUG - Creating task: eval-line
[2011-09-06 21:36:09] (8063) DEBUG -    server: centos6
[2011-09-06 21:36:09] (8063) DEBUG -    server: funtoo
[2011-09-06 21:36:09] (8063) - INFO - Running task: eval-line
[2011-09-06 21:36:09] (8063) DEBUG -    server: centos6
[2011-09-06 21:36:09] (8063) DEBUG -    server: funtoo
[2011-09-06 21:36:09] (8063) DEBUG - Using user: root
[2011-09-06 21:36:09] (8063) DEBUG - Using password: <no password>
[2011-09-06 21:36:09] (8063) DEBUG - My Hostname: merkur
[2011-09-06 21:36:09] (8063) DEBUG - My Shortname: merkur
[2011-09-06 21:36:09] (8063) DEBUG - Next Server: centos6
[2011-09-06 21:36:09] (8086) - INFO - Connecting to centos6 (root)
[2011-09-06 21:36:09] (8086) DEBUG - Current Error-Code: -37
[2011-09-06 21:36:09] (8086) - INFO - Connected to centos6, trying to authenticate.
[2011-09-06 21:36:09] (8063) DEBUG - Next Server: funtoo
[2011-09-06 21:36:09] (8120) - INFO - Connecting to funtoo (root)
[2011-09-06 21:36:09] (8120) DEBUG - Current Error-Code: -37
[2011-09-06 21:36:09] (8120) - INFO - Connected to funtoo, trying to authenticate.
[2011-09-06 21:36:09] (8063) DEBUG - Waiting for children to finish
[2011-09-06 21:36:09] (8063) DEBUG - Initializing Logger from parameters found in Rexfile
[2011-09-06 21:36:09] (8063) DEBUG - Removing lockfile
[2011-09-06 21:36:09] (8063) DEBUG - Unlinking files: Rexfile.lock

The same works flawlessly with openssh after preloading protected ssh key into ssh-agent:

ganto@merkur ~ $ for server in centos6 funtoo; do ssh -i ~/.ssh/id_admin_rsa $server uptime; done
21:48:12 up 2 days, 20:49,  0 users,  load average: 0.00, 0.00, 0.00
21:48:12 up 48 min,  1 user,  load average: 0.00, 0.01, 0.05

Btw... I think this tool has potential to be very handy in the datacenter. I'm looking forward to see it work :-)

Kind regards, Reto

-G parameter fails in latest DEB build

Hey

After the last update over apt the -G parameter doesn't seem to work for me. Instead of looking up the group, it uses the parameter as the hostname itself.

root@rex:~/tasks# rex -G "nameserver" update
[2012-08-17 17:50:23] INFO - Connecting to nameserver:22 (root)
[2012-08-17 17:50:24] INFO - Connecting to nameserver:22 (root)
[2012-08-17 17:50:25] INFO - Connecting to nameserver:22 (root)
[2012-08-17 17:50:26] INFO - Can't connect to nameserver
[2012-08-17 17:50:26] INFO - Wrong username or password. Or wrong key.

auth for with wildcard

to set auth info for multiple groups / tasks at once.

auth for => qr{^.*:deploy$} =>
   user => "foo",
   password => "bar";

Feature request - download URL

Hi,

it would be really great if I could do the following.

---snip---

Application version

my $app_name = "homepage_";
my $app_version = "1.1.1";
my $package = "${app_name}${app_version}.zip";

desc "Download package";
task "download", "server01", sub {
download "/opt/sc/etc/httpd/dev-packages/frontend/${package}", ".";
};
---snap---
instead of

---snip---
...
download "/opt/sc/etc/httpd/dev-packages/frontend/${package}", "${package}";
...
---snap---
I mean that the src filename should be the destination filename.

Cheers,

Matthias

Extend of virtualization

Hello,

At first thanks for this project, it's a really must have for me !

I have wrote a little extension for virtualization module, if you are interested.

print Dumper vm blklist => "domName", details => 1, unit => 1024_1024_1024;

[ Details ] and [ unit ] are optionals

print Dumper vm iflist => "domName";

I haven't find a way to attach file to issue, then I copy/paste the code :


#
# (c) Jan Gehring <[email protected]>
#
# vim: set ts=3 sw=3 tw=0:
# vim: set expandtab:
package Rex::Virtualization::LibVirt::iflist;

use strict;
use warnings;

use Rex::Logger;
use Rex::Commands::Run;

use Data::Dumper;

sub execute {
   shift;
   my $vmname = shift;
   my %options = @_;

   unless($vmname) {
      die("You have to define the vm name!");
   }

   Rex::Logger::debug("Getting interface list of domain: $vmname");

   my @iflist = run "virsh domiflist $vmname";

   if($? != 0) {
      die("Error running virsh domiflist $vmname");
   }

   my %ret = ();
   my ($k, $v);

   shift @iflist;
   shift @iflist;
   for my $line (@iflist) {
      my ($interface, $type, $source, $model, $mac) = split(/\s+/, $line);
      $ret{$interface} = {
         type => $type,
         source => $source,
         model => $model,
         mac => $mac
      };
   }

   return \%ret;
}

1;

------------------------------------------------------------------
#
# (c) Jan Gehring <[email protected]>
#
# vim: set ts=3 sw=3 tw=0:
# vim: set expandtab:

package Rex::Virtualization::LibVirt::blklist;

use strict;
use warnings;

use Rex::Logger;
use Rex::Commands::Run;

use Data::Dumper;

sub execute {
   shift;
   my $vmname = shift;
   my %options = @_;

   unless($vmname) {
      die("You have to define the vm name!");
   }

   Rex::Logger::debug("Getting block list of domain: $vmname");

   my @blklist = run "virsh domblklist $vmname --details";

   if($? != 0) {
      die("Error running virsh domblklist $vmname");
   }

   my %ret = ();
   my ($k, $v);

   shift @blklist;
   shift @blklist;
   for my $line (@blklist) {
      my ($type, $device, $target, $source) = split(/\s+/, $line);
      $ret{$target} = {
         type => $type,
         device => $device,
         source => $source
      };
   }

   if (%options) {
      if ($options{details}) {
         my $unit = $options{unit} || 1;
         for my $target (keys %ret) {
            my @infos = run "virsh domblkinfo $vmname $target 2>/dev/null";
            if($? == 0) {
               for my $line (@infos) {
                  my ($k, $v) = split(/:\s+/, $line);
                  $ret{$target}->{$k} = $v / $unit;
               }
            }
         }
      }
   }

   return \%ret;
}

1;

Rex Crashes on Windows.

In my test.

Rexfile

parallelism 4;
no_ssh task "test", ("localhost")x10, sub {
    LOCAL { say run('echo '.Rex::get_current_connection()->{server}) };
};

When I run "rex test", Rex crashes with "Free to wrong pool...." error message.
There is no difference between with parallelism and without parallelism.

>rex test
[2011-09-30 11:21:00] (53344) - INFO - Running task: test
Use of uninitialized value $user in concatenation (.) or string at C:/strawberry-perl-5.12.3.0-portable/perl/site/lib/Rex/Task.pm line 175.
localhost
Free to wrong pool 2620790 not 144ed80 at C:/strawberry-perl-5.12.3.0-portable/perl/vendor/lib/Win32/EventLog.pm line 110.
localhost
localhost
localhost
localhost
localhost
localhost
localhost



>rex test
[2011-09-30 11:21:06] (53528) - INFO - Running task: test
Use of uninitialized value $user in concatenation (.) or string at C:/strawberry-perl-5.12.3.0-portable/perl/site/lib/Rex/Task.pm line 175.
localhost
Free to wrong pool 2530790 not 12ded80 at C:/strawberry-perl-5.12.3.0-portable/perl/vendor/lib/Win32/EventLog.pm line 110.

So i degugged with perl -d option.

Debug message.

>perl -d ./rex test

Loading DB routines from perl5db.pl version 1.33
Editor support available.

Enter h or `h h' for help, or `perldoc perldebug' for more help.

main::(./rex:50):       $|++;
  DB<1> r
[2011-09-30 11:15:58] (51564) - INFO - Running task: test
localhost
Attempt to free unreferenced scalar: SV 0x393ed4c, Perl interpreter: 0x2bfdb54 at C:/strawberry-perl-5.12.3.0-portable/perl/site/lib/Rex/Task.pm line 285.
 at C:/strawberry-perl-5.12.3.0-portable/perl/site/lib/Rex/Task.pm line 285
Attempt to free unreferenced scalar: SV 0x393ed6c, Perl interpreter: 0x2bfdb54 at C:/strawberry-perl-5.12.3.0-portable/perl/site/lib/Rex/Task.pm line 285.
 at C:/strawberry-perl-5.12.3.0-portable/perl/site/lib/Rex/Task.pm line 285
Argument "__DIE__" isn't numeric in addition (+) at C:/strawberry-perl-5.12.3.0-portable/perl/lib/perl5db.pl line 3666.
Use of uninitialized value $DB::stack_depth in addition (+) at C:/strawberry-perl-5.12.3.0-portable/perl/lib/perl5db.pl line 3666.
 at C:/strawberry-perl-5.12.3.0-portable/perl/lib/perl5db.pl line 3666
        eval {...} called at C:/strawberry-perl-5.12.3.0-portable/perl/site/lib/Rex/Task.pm line 285
Free to wrong pool 2ca2c30 not 72ed40 at C:/strawberry-perl-5.12.3.0-portable/perl/vendor/lib/Win32/EventLog.pm line 110.
 at C:/strawberry-perl-5.12.3.0-portable/perl/vendor/lib/Win32/EventLog.pm line 110
        Win32::EventLog::Close('Win32::EventLog=HASH(0x302b0ac)') called at C:/strawberry-perl-5.12.3.0-portable/perl/site/lib/Sys/Syslog.pm line 837
        Sys::Syslog::disconnect_log() called at C:/strawberry-perl-5.12.3.0-portable/perl/site/lib/Sys/Syslog.pm line 181
        Sys::Syslog::closelog() called at C:/strawberry-perl-5.12.3.0-portable/perl/site/lib/Rex/Logger.pm line 67
        Rex::Logger::END() called at C:/strawberry-perl-5.12.3.0-portable/perl/site/lib/Rex/Task.pm line 285
        eval {...} called at C:/strawberry-perl-5.12.3.0-portable/perl/site/lib/Rex/Task.pm line 285

I heard that "Free to wrong pool .." error caused by different Perl's thread behavior(fork emulation) between unix and windows.

Commands::File::extract is interactive

call it on the same .gz file twice - the second time it'll ask you questions. (locally)

also - it'd be nice if it told us what the resultant files were.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.