cancel
Showing results for 
Search instead for 
Did you mean: 

Script to add banner for multiple devices

Script to add banner for multiple devices

EtherNation_Use
Contributor II
Create Date: May 21 2012 8:03AM

I would like to create script that will ad banner to my devices.

Currentli have issues with diferent commands on XOS and Extremeware.

Also when i add in script something like:

configure banner before-login

************************************************************

UNAUTHORIZED ACCESS

************************************************************



It gets stuck and cannot execute.

(from Davor_Gadanac)
9 REPLIES 9

EtherNation_Use
Contributor II
Create Date: Nov 27 2013 2:16AM

I wonder how did you have the LF added to your text file because that is a non printed character.

I have created a simple script to add that to the file and it worked really well.

Download the attached file (right-click, Save Target As) and remove the "txt" extension, then try it.

Do not modify the file yet - just try it first to see that if works. To modify it, open it in a text editor (SciTe, Notepad + or other editor which allows you to see the end of line characters). Modify the file and keep the LFs at the end. Once you save it - check it again to see if the LFs haven't been replaced with CRLFs, then run it again.

Or easier if you're even a bit familiar with VisualBasic or any other scripting language:
- have the text file ready with the text you want
- write a short VB script to
- read the file
- replace CRLF with LF
- save the file

job done 🙂

banner.xsf.txt (from Eugen_NAIMAN)

EtherNation_Use
Contributor II
Create Date: Nov 26 2013 3:12PM

Hello,

someone have an example with a hit "enter" key ?

Because when I test a script write in Ridgeline and execute on an equipment, it already stay at the first line and causes a timeout.

My script is very simple :

configure banner before-login
bannertest
\r\r

I've tested to replace \r\r with or with LF command.

Thanks for any help.

(from tristan)

EtherNation_Use
Contributor II
Create Date: Oct 27 2012 12:08AM

Donno if you guys figured this out. But i have done this before.

This is how it works

line1....
#blank line
line2
end script with two enters

Thanks,
Arpit
(from Arpit_Bhatt)

EtherNation_Use
Contributor II
Create Date: Oct 22 2012 5:11PM

I have this same question. I think I'm stuck on the carriage return and linefeed. How do I send that through to the switch from the script?

Here is what I am trying right now:

configure banner
this is the banner\r\n
\r\n

(from Ryan_Moore)
GTM-P2G8KFN