Welcome, Guest. Please login or register.

Author Topic: Config backup error: config is less than 3 lines  (Read 3245 times)

Andy_30

  • Guest
Config backup error: config is less than 3 lines
« on: October 20, 2011, 12:43:37 PM »
Hi Everybody,
running nedi.pl -v -p -B over WAN MPLS 4Mbps utilized in 50% connection for some devices I obtain following message: "Config backup error: config is less than 3 lines".
do you know where is the problem?




Hinton

  • Guest
Re: Config backup error: config is less than 3 lines
« Reply #1 on: November 14, 2011, 01:47:28 PM »
Did you get this fixed?  I noticed the same thing on one of our devices - a 4510 - the only one i see giving us problems
have the exact same message -  config is less than 3 lines

rickli

  • Administrator
  • Hero Member
  • *****
  • Posts: 2687
    • View Profile
    • NeDi
Re: Config backup error: config is less than 3 lines
« Reply #2 on: November 19, 2011, 11:51:47 AM »
Try it with -v if you see the actual config scrolling through you most likely need to increase the timeout...
Please consider Other-Invoices on your NeDi installation for an annual contribution, tx!
-Remo

Fiss

  • Guest
Re: Config backup error: config is less than 3 lines
« Reply #3 on: July 03, 2012, 12:55:13 PM »
Hi,

Same problem here with a Nexus 5548.
Quite weird in fact, nedi authenticate by ssh and push the commands. The config is correctly prompted but then, i get the error :

Quote
Use of uninitialized value $misc::curcfg[0] in concatenation (.) or string at ./inc/libcli-iopty.pm line 827.
ERR :No config ()
DISC:Config backup error: config is less than 3 lines

I've already tried to increase the timeout value as mentionned by Remo but without luck.

For example, nedi backups perfectly my Cisco ASA FW configs by ssh.

I use nedi version 1.0.7 with the command ./nedi.pl -bIdv -a www.xxx.yyy.zzz

rickli

  • Administrator
  • Hero Member
  • *****
  • Posts: 2687
    • View Profile
    • NeDi
Re: Config backup error: config is less than 3 lines
« Reply #4 on: July 03, 2012, 08:43:11 PM »
What lines do you see after "show running-config" is sent? Have a look at inc/libcli-pty.pm and verify the used NXOS commands actually work on your boxes. Seems there is some inconsistency...

BTW, what's -I for?  :)
n7dev:/var/nedi#grep opt{'I'} *.pl
n7dev:/var/nedi#grep opt{'I'} inc/*.pm
n7dev:/var/nedi#
Please consider Other-Invoices on your NeDi installation for an annual contribution, tx!
-Remo

Fiss

  • Guest
Re: Config backup error: config is less than 3 lines
« Reply #5 on: July 05, 2012, 01:13:40 PM »
Hi Remo !

The -I was used in a previous version we had . It was the 1.0.5 i believe.

Anyway, i tried to optimise the NXOS part of the script with same results (cf attached files).

Thanks for you help

Fiss

rickli

  • Administrator
  • Hero Member
  • *****
  • Posts: 2687
    • View Profile
    • NeDi
Re: Config backup error: config is less than 3 lines
« Reply #6 on: July 05, 2012, 06:42:21 PM »
I thought something like this, but I don't even remember what -I was for  :D

Interesting, you see the whole config correctly in the output.log? What about the CLI output above the error?

Here's an example of a successful router backup:

CMD :terminal length 0,
CMD :show run
WAIT:Building configuration...
WAIT:
CONF:Current configuration : 1044 bytes
CONF:!
CONF:version 12.2
.
.
.
CONF:!
CONF:end
WAIT:
CONF:81 lines read
Please consider Other-Invoices on your NeDi installation for an annual contribution, tx!
-Remo

Fiss

  • Guest
Re: Config backup error: config is less than 3 lines
« Reply #7 on: July 06, 2012, 11:19:19 AM »
Yes, the whole config is shown in both the output.log and the CLI output.

The CLI output just before the error is currently the end of the config of the nexus :

Code: [Select]
WAIT:    area 0.0.0.0 authentication message-digest
WAIT:
WAIT:
Use of uninitialized value $misc::curcfg[0] in concatenation (.) or string at ./inc/libcli-iopty.pm line 836.
ERR :No config ()
DISC:Config backup error: config is less than 3 lines
MLQ :lme+ f06gigsw01: Config backup error: config is less than 3 lines

Fiss

  • Guest
Re: Config backup error: config is less than 3 lines
« Reply #8 on: July 06, 2012, 02:19:34 PM »
I suddenly realised the "WAIT:" tag instead of the "CONF:" one in the output...  :o

Any clues ?

Fiss

rickli

  • Administrator
  • Hero Member
  • *****
  • Posts: 2687
    • View Profile
    • NeDi
Re: Config backup error: config is less than 3 lines
« Reply #9 on: July 06, 2012, 07:39:16 PM »
Good, I knew it's gotta be around there ;)

Check the strt variable in inc/libcli-iopty.pm against the start of your config. I got "^begin" in there now, but if that never matches it just keeps waiting without ever putting anything into the config (hence this ugly error message)...
Please consider Other-Invoices on your NeDi installation for an annual contribution, tx!
-Remo