simple, and to the point. Thank you
Michel
------------------------------
Michel Lapointe
------------------------------
Original Message:
Sent: 08-16-2021 12:29
From: Unknown User
Subject: get switchname as variable
root@switch:RE:0% touch test
root@switch:RE:0% mv test test-`hostname`
root@switch:RE:0% ls -la test*
-rw-r--r-- 1 root wheel 0 Aug 16 18:26 test-switch
Original Message:
Sent: 08-16-2021 08:58
From: Michel Lapointe
Subject: get switchname as variable
Hello,
I am looking for a quick way to do the following:
· This is my switch..... root@mrct-nddn-02- >
· This is a text file on my switch ..... testData
· I want to issue a Junos or Linux command to do the following: rename "testdata" as "mrct-nddn-02_testData"
Is there a quick Junos or Linux way to get my switch name and append it to the file name ?
Thanks
Michel lapointe