Discussion:
[xcat-user] bash expansions and node ranges
Christopher J. Walker
2017-06-21 21:25:43 UTC
Permalink
Having just tried to reprovision two nodes (dn22 and dn23), I've
reprovisioned dn2 instead.

The command I ran was:

[***@mgt.apocrita consoles]# rinstall dn[22-23]
--osimage="apocrita-centos7.3-x86_64-install-compute" -u
Provision node(s): dn2

Needless to say, this hasn't been popular with the user running jobs on
the node. This of course would work correctly with differently named
files in the directory.


Perhaps
http://xcat-docs.readthedocs.io/en/stable/guides/admin-guides/references/man3/noderange.3.html

could warn about the necessity of quoting these on the command line (and
even better give an example).

Chris

--
Dr Christopher J. Walker
ITS Research
Queen Mary University of London, E1 4NS
+44 20 7882 5969
Mark Gurevich
2017-06-22 02:04:18 UTC
Permalink
Chris,

Interesting find.
What do you see when you run "nodels dn[22-23]" ?

Mark Gurevich
Poughkeepsie Development Lab
HPC Software Development - xCAT

"If we knew what it was we were doing, it would not be called research,
would it?"
--Albert Einstein





From: "Christopher J. Walker" <***@qmul.ac.uk>
To: "xcat-***@lists.sourceforge.net"
<xcat-***@lists.sourceforge.net>
Date: 06/21/2017 05:26 PM
Subject: [xcat-user] bash expansions and node ranges



Having just tried to reprovision two nodes (dn22 and dn23), I've
reprovisioned dn2 instead.

The command I ran was:

[***@mgt.apocrita consoles]# rinstall dn[22-23]
--osimage="apocrita-centos7.3-x86_64-install-compute" -u
Provision node(s): dn2

Needless to say, this hasn't been popular with the user running jobs on
the node. This of course would work correctly with differently named
files in the directory.


Perhaps
http://xcat-docs.readthedocs.io/en/stable/guides/admin-guides/references/man3/noderange.3.html


could warn about the necessity of quoting these on the command line (and
even better give an example).

Chris

--
Dr Christopher J. Walker
ITS Research
Queen Mary University of London, E1 4NS
+44 20 7882 5969
Victor Hu
2017-06-22 03:29:35 UTC
Permalink
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
Christopher J. Walker
2017-06-22 18:43:12 UTC
Permalink
On 22/06/17 04:29, Victor Hu wrote:
> Hi Chris,
>
> Could you open it issue for this here? :
> https://github.com/xcat2/xcat-core/issues/
> Would be better to track the debug conversation and a fix if needed.

https://github.com/xcat2/xcat-core/issues/3319

Chris
>
> Thanks,
> Victor
>
>
>
>
>
>
> ----- Original message -----
> From: "Mark Gurevich" <***@us.ibm.com>
> To: xCAT Users Mailing list <xcat-***@lists.sourceforge.net>
> Cc:
> Subject: Re: [xcat-user] bash expansions and node ranges
> Date: Wed, Jun 21, 2017 10:05 PM
>
> Chris,
>
> Interesting find.
> What do you see when you run "nodels dn[22-23]" ?
>
> Mark Gurevich
> Poughkeepsie Development Lab
> HPC Software Development - xCAT
>
> "If we knew what it was we were doing, it would not be called
> research, would it?"
> --Albert Einstein
>
>
>
>
>
> From: "Christopher J. Walker" <***@qmul.ac.uk>
> To: "xcat-***@lists.sourceforge.net"
> <xcat-***@lists.sourceforge.net>
> Date: 06/21/2017 05:26 PM
> Subject: [xcat-user] bash expansions and node ranges
> ------------------------------------------------------------------------
>
>
>
> Having just tried to reprovision two nodes (dn22 and dn23), I've
> reprovisioned dn2 instead.
>
> The command I ran was:
>
> [***@mgt.apocrita consoles]# rinstall dn[22-23]
> --osimage="apocrita-centos7.3-x86_64-install-compute" -u
> Provision node(s): dn2
>
> Needless to say, this hasn't been popular with the user running jobs on
> the node. This of course would work correctly with differently named
> files in the directory.
>
>
> Perhaps
> http://xcat-docs.readthedocs.io/en/stable/guides/admin-guides/references/man3/noderange.3.html
>
> could warn about the necessity of quoting these on the command line (and
> even better give an example).
>
> Chris
>
> --
> Dr Christopher J. Walker
> ITS Research
> Queen Mary University of London, E1 4NS
> +44 20 7882 5969
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> xCAT-user mailing list
> xCAT-***@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/xcat-user
>
>
>
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> xCAT-user mailing list
> xCAT-***@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/xcat-user
>
>
>
>
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>
>
>
> _______________________________________________
> xCAT-user mailing list
> xCAT-***@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/xcat-user
>


--
Dr Christopher J. Walker
ITS Research
Queen Mary University of London, E1 4NS
+44 20 7882 5969
Jarrod Johnson
2017-06-22 19:14:58 UTC
Permalink
Perhaps we should put aliases for all the non-file related commands in profile.d? For example:

[***@odin ~]# touch n1
[***@odin ~]# nodeset n[1,2] shell
n1: shell

Well whoops, but.... then if we:


[***@odin ~]# alias nodeset='set -f;nodeset';nodeset(){ command nodeset "$@";set +f;}
[***@odin ~]# nodeset n[1,2] shell
n1: shell
n2: shell


-----Original Message-----
From: Christopher J. Walker [mailto:***@qmul.ac.uk]
Sent: Thursday, June 22, 2017 2:43 PM
To: xcat-***@lists.sourceforge.net
Subject: Re: [xcat-user] bash expansions and node ranges

On 22/06/17 04:29, Victor Hu wrote:
> Hi Chris,
>
> Could you open it issue for this here? :
> https://github.com/xcat2/xcat-core/issues/
> Would be better to track the debug conversation and a fix if needed.

https://github.com/xcat2/xcat-core/issues/3319

Chris
>
> Thanks,
> Victor
>
>
>
>
>
>
> ----- Original message -----
> From: "Mark Gurevich" <***@us.ibm.com>
> To: xCAT Users Mailing list <xcat-***@lists.sourceforge.net>
> Cc:
> Subject: Re: [xcat-user] bash expansions and node ranges
> Date: Wed, Jun 21, 2017 10:05 PM
>
> Chris,
>
> Interesting find.
> What do you see when you run "nodels dn[22-23]" ?
>
> Mark Gurevich
> Poughkeepsie Development Lab
> HPC Software Development - xCAT
>
> "If we knew what it was we were doing, it would not be called
> research, would it?"
> --Albert Einstein
>
>
>
>
>
> From: "Christopher J. Walker" <***@qmul.ac.uk>
> To: "xcat-***@lists.sourceforge.net"
> <xcat-***@lists.sourceforge.net>
> Date: 06/21/2017 05:26 PM
> Subject: [xcat-user] bash expansions and node ranges
>
> ----------------------------------------------------------------------
> --
>
>
>
> Having just tried to reprovision two nodes (dn22 and dn23), I've
> reprovisioned dn2 instead.
>
> The command I ran was:
>
> [***@mgt.apocrita consoles]# rinstall dn[22-23]
> --osimage="apocrita-centos7.3-x86_64-install-compute" -u
> Provision node(s): dn2
>
> Needless to say, this hasn't been popular with the user running jobs on
> the node. This of course would work correctly with differently named
> files in the directory.
>
>
> Perhaps
>
> http://xcat-docs.readthedocs.io/en/stable/guides/admin-guides/referenc
> es/man3/noderange.3.html
>
> could warn about the necessity of quoting these on the command line (and
> even better give an example).
>
> Chris
>
> --
> Dr Christopher J. Walker
> ITS Research
> Queen Mary University of London, E1 4NS
> +44 20 7882 5969
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> xCAT-user mailing list
> xCAT-***@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/xcat-user
>
>
>
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> xCAT-user mailing list
> xCAT-***@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/xcat-user
>
>
>
>
>
> ----------------------------------------------------------------------
> -------- Check out the vibrant tech community on one of the world's
> most engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>
>
>
> _______________________________________________
> xCAT-user mailing list
> xCAT-***@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/xcat-user
>


--
Dr Christopher J. Walker
ITS Research
Queen Mary University of London, E1 4NS
+44 20 7882 5969

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
xCAT-user mailing list
xCAT-***@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/xcat-user
Jarrod Johnson
2017-06-22 19:43:57 UTC
Permalink
Example (committed already to confluent):
https://github.com/jjohnson42/confluent/commit/1526a9b92d208223d74bfcf2ecdb52c366705a37

-----Original Message-----
From: Jarrod Johnson [mailto:***@lenovo.com]
Sent: Thursday, June 22, 2017 3:15 PM
To: xCAT Users Mailing list
Subject: Re: [xcat-user] bash expansions and node ranges

Perhaps we should put aliases for all the non-file related commands in profile.d? For example:

[***@odin ~]# touch n1
[***@odin ~]# nodeset n[1,2] shell
n1: shell

Well whoops, but.... then if we:


[***@odin ~]# alias nodeset='set -f;nodeset';nodeset(){ command nodeset "$@";set +f;} [***@odin ~]# nodeset n[1,2] shell
n1: shell
n2: shell


-----Original Message-----
From: Christopher J. Walker [mailto:***@qmul.ac.uk]
Sent: Thursday, June 22, 2017 2:43 PM
To: xcat-***@lists.sourceforge.net
Subject: Re: [xcat-user] bash expansions and node ranges

On 22/06/17 04:29, Victor Hu wrote:
> Hi Chris,
>
> Could you open it issue for this here? :
> https://github.com/xcat2/xcat-core/issues/
> Would be better to track the debug conversation and a fix if needed.

https://github.com/xcat2/xcat-core/issues/3319

Chris
>
> Thanks,
> Victor
>
>
>
>
>
>
> ----- Original message -----
> From: "Mark Gurevich" <***@us.ibm.com>
> To: xCAT Users Mailing list <xcat-***@lists.sourceforge.net>
> Cc:
> Subject: Re: [xcat-user] bash expansions and node ranges
> Date: Wed, Jun 21, 2017 10:05 PM
>
> Chris,
>
> Interesting find.
> What do you see when you run "nodels dn[22-23]" ?
>
> Mark Gurevich
> Poughkeepsie Development Lab
> HPC Software Development - xCAT
>
> "If we knew what it was we were doing, it would not be called
> research, would it?"
> --Albert Einstein
>
>
>
>
>
> From: "Christopher J. Walker" <***@qmul.ac.uk>
> To: "xcat-***@lists.sourceforge.net"
> <xcat-***@lists.sourceforge.net>
> Date: 06/21/2017 05:26 PM
> Subject: [xcat-user] bash expansions and node ranges
>
> ----------------------------------------------------------------------
> --
>
>
>
> Having just tried to reprovision two nodes (dn22 and dn23), I've
> reprovisioned dn2 instead.
>
> The command I ran was:
>
> [***@mgt.apocrita consoles]# rinstall dn[22-23]
> --osimage="apocrita-centos7.3-x86_64-install-compute" -u
> Provision node(s): dn2
>
> Needless to say, this hasn't been popular with the user running jobs on
> the node. This of course would work correctly with differently named
> files in the directory.
>
>
> Perhaps
>
> http://xcat-docs.readthedocs.io/en/stable/guides/admin-guides/referenc
> es/man3/noderange.3.html
>
> could warn about the necessity of quoting these on the command line (and
> even better give an example).
>
> Chris
>
> --
> Dr Christopher J. Walker
> ITS Research
> Queen Mary University of London, E1 4NS
> +44 20 7882 5969
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> xCAT-user mailing list
> xCAT-***@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/xcat-user
>
>
>
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> xCAT-user mailing list
> xCAT-***@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/xcat-user
>
>
>
>
>
> ----------------------------------------------------------------------
> -------- Check out the vibrant tech community on one of the world's
> most engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>
>
>
> _______________________________________________
> xCAT-user mailing list
> xCAT-***@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/xcat-user
>


--
Dr Christopher J. Walker
ITS Research
Queen Mary University of London, E1 4NS
+44 20 7882 5969

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot _______________________________________________
xCAT-user mailing list
xCAT-***@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/xcat-user

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot _______________________________________________
xCAT-user mailing list
xCAT-***@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/xcat-user
Jarrod Johnson
2017-06-22 19:52:08 UTC
Permalink
Err.. https://github.com/jjohnson42/confluent/commit/e4186841b4699ea22effa9352329c835a6838d2d

-----Original Message-----
From: Jarrod Johnson [mailto:***@lenovo.com]
Sent: Thursday, June 22, 2017 3:44 PM
To: xCAT Users Mailing list
Subject: Re: [xcat-user] bash expansions and node ranges

Example (committed already to confluent):
https://github.com/jjohnson42/confluent/commit/1526a9b92d208223d74bfcf2ecdb52c366705a37

-----Original Message-----
From: Jarrod Johnson [mailto:***@lenovo.com]
Sent: Thursday, June 22, 2017 3:15 PM
To: xCAT Users Mailing list
Subject: Re: [xcat-user] bash expansions and node ranges

Perhaps we should put aliases for all the non-file related commands in profile.d? For example:

[***@odin ~]# touch n1
[***@odin ~]# nodeset n[1,2] shell
n1: shell

Well whoops, but.... then if we:


[***@odin ~]# alias nodeset='set -f;nodeset';nodeset(){ command nodeset "$@";set +f;} [***@odin ~]# nodeset n[1,2] shell
n1: shell
n2: shell


-----Original Message-----
From: Christopher J. Walker [mailto:***@qmul.ac.uk]
Sent: Thursday, June 22, 2017 2:43 PM
To: xcat-***@lists.sourceforge.net
Subject: Re: [xcat-user] bash expansions and node ranges

On 22/06/17 04:29, Victor Hu wrote:
> Hi Chris,
>
> Could you open it issue for this here? :
> https://github.com/xcat2/xcat-core/issues/
> Would be better to track the debug conversation and a fix if needed.

https://github.com/xcat2/xcat-core/issues/3319

Chris
>
> Thanks,
> Victor
>
>
>
>
>
>
> ----- Original message -----
> From: "Mark Gurevich" <***@us.ibm.com>
> To: xCAT Users Mailing list <xcat-***@lists.sourceforge.net>
> Cc:
> Subject: Re: [xcat-user] bash expansions and node ranges
> Date: Wed, Jun 21, 2017 10:05 PM
>
> Chris,
>
> Interesting find.
> What do you see when you run "nodels dn[22-23]" ?
>
> Mark Gurevich
> Poughkeepsie Development Lab
> HPC Software Development - xCAT
>
> "If we knew what it was we were doing, it would not be called
> research, would it?"
> --Albert Einstein
>
>
>
>
>
> From: "Christopher J. Walker" <***@qmul.ac.uk>
> To: "xcat-***@lists.sourceforge.net"
> <xcat-***@lists.sourceforge.net>
> Date: 06/21/2017 05:26 PM
> Subject: [xcat-user] bash expansions and node ranges
>
> ----------------------------------------------------------------------
> --
>
>
>
> Having just tried to reprovision two nodes (dn22 and dn23), I've
> reprovisioned dn2 instead.
>
> The command I ran was:
>
> [***@mgt.apocrita consoles]# rinstall dn[22-23]
> --osimage="apocrita-centos7.3-x86_64-install-compute" -u
> Provision node(s): dn2
>
> Needless to say, this hasn't been popular with the user running jobs on
> the node. This of course would work correctly with differently named
> files in the directory.
>
>
> Perhaps
>
> http://xcat-docs.readthedocs.io/en/stable/guides/admin-guides/referenc
> es/man3/noderange.3.html
>
> could warn about the necessity of quoting these on the command line (and
> even better give an example).
>
> Chris
>
> --
> Dr Christopher J. Walker
> ITS Research
> Queen Mary University of London, E1 4NS
> +44 20 7882 5969
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> xCAT-user mailing list
> xCAT-***@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/xcat-user
>
>
>
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> xCAT-user mailing list
> xCAT-***@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/xcat-user
>
>
>
>
>
> ----------------------------------------------------------------------
> -------- Check out the vibrant tech community on one of the world's
> most engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>
>
>
> _______________________________________________
> xCAT-user mailing list
> xCAT-***@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/xcat-user
>


--
Dr Christopher J. Walker
ITS Research
Queen Mary University of London, E1 4NS
+44 20 7882 5969

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot _______________________________________________
xCAT-user mailing list
xCAT-***@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/xcat-user

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot _______________________________________________
xCAT-user mailing list
xCAT-***@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/xcat-user

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot _______________________________________________
xCAT-user mailing list
xCAT-***@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/xcat-user
Christopher Samuel
2017-06-22 03:45:57 UTC
Permalink
On 22/06/17 07:25, Christopher J. Walker wrote:

> The command I ran was:
>
> [***@mgt.apocrita consoles]# rinstall dn[22-23]
> --osimage="apocrita-centos7.3-x86_64-install-compute" -u
> Provision node(s): dn2

What do you get if you put an "echo" in front of that?

My guess is that there's a file called dn2 in that directory.

cheers,
Chris
--
Christopher Samuel Senior Systems Administrator
Melbourne Bioinformatics - The University of Melbourne
Email: ***@unimelb.edu.au Phone: +61 (0)3 903 55545
Christopher J. Walker
2017-06-22 18:39:57 UTC
Permalink
On 22/06/17 04:45, Christopher Samuel wrote:
> On 22/06/17 07:25, Christopher J. Walker wrote:
>
>> The command I ran was:
>>
>> [***@mgt.apocrita consoles]# rinstall dn[22-23]
>> --osimage="apocrita-centos7.3-x86_64-install-compute" -u
>> Provision node(s): dn2
>
> What do you get if you put an "echo" in front of that?
>
> My guess is that there's a file called dn2 in that directory.
>

That's exactly the problem:

cd /var/-bash-4.1$ cd /var/log/consoles/
-bash-4.1$ echo dn[22-23]
dn2 dn3
-bash-4.1$ ls -l dn2
-rw-r--r-- 1 root root 1677108 Jun 21 23:02 dn2
-bash-4.1$ ls -l dn3
-rw-r--r-- 1 root root 2035512 Jun 17 23:06 dn3


Chris
--
Dr Christopher J. Walker
ITS Research
Queen Mary University of London, E1 4NS
+44 20 7882 5969
Loading...