From: bobneworleans on
Is it possible to directly edit the Env_Vars file using IOS?
Is it possible to drop from IOS into the underlying linux kernel?
From: Doug McIntyre on
"bobneworleans(a)yahoo.com" <bobneworleans(a)yahoo.com> writes:
>Is it possible to directly edit the Env_Vars file using IOS?
>Is it possible to drop from IOS into the underlying linux kernel?

You don't say what platform this is, but env_vars filename tends to
point me to a small-to-mid range switch platform (ie. 2960).

You can't generally edit files inside IOS, if they aren't protected,
you can copy things around after you edit them externally. I don't
really desire to try to trash my switches with overwriting system
files though, so I'd let you try something like

copy ftp://host/env_vars flash:env_vars

yourself though. Don't know what you hope to gain by doing anything of
the sort. If this is to attempt to bypass some sort of licensing, I'm
sure cisco would protect any sensative files, or hold the info
elsewhere (ie. cookie PROM?) that is not going to be easily touchable,
or viewable.

Generally, things running the OS known as IOS aren't running linux, so
there's no way into something that doesn't exist. The command shell
that you get is the only physical interaction you get with the OS.

Even on the cisco devices that do happen to run linux kernel (ie. NX-OS),
the command shell again is the only interaction with the OS. I assume you
are thinking of running bash or some other type of shell, and that
isn't going to happen.

From: bobneworleans on
On Jul 8, 1:00 pm, Doug McIntyre <mer...(a)geeks.org> wrote:
> "bobneworle...(a)yahoo.com" <bobneworle...(a)yahoo.com> writes:
> >Is it possible to directly edit the Env_Vars file using IOS?
> >Is it possible to drop from IOS into the underlying linux kernel?
>
> You don't say what platform this is, but env_vars filename tends to
> point me to a small-to-mid range switch platform (ie. 2960).
>
> You can't generally edit files inside IOS, if they aren't protected,
> you can copy things around after you edit them externally. I don't
> really desire to try to trash my switches with overwriting system
> files though, so I'd let you try something like
>
>       copyftp://host/env_varsflash:env_vars
>
> yourself though. Don't know what you hope to gain by doing anything of
> the sort. If this is to attempt to bypass some sort of licensing, I'm
> sure cisco would protect any sensative files, or hold the info
> elsewhere (ie. cookie PROM?) that is not going to be easily touchable,
> or viewable.
>
> Generally, things running the OS known as IOS aren't running linux, so
> there's no way into something that doesn't exist. The command shell
> that you get is the only physical interaction you get with the OS.
>
> Even on the cisco devices that do happen to run linux kernel (ie. NX-OS),
> the command shell again is the only interaction with the OS. I assume you
> are thinking of running bash or some other type of shell, and that
> isn't going to happen.

Doug,
Thanks for the informative reply.

I'm working with a 1231 AP. I had addressed the BVI1 interface as
10.1.105.100 as a temporary work-around while DHCP was down. Now
after rebooting the AP, DHCP gives it a valid lease but the AP
releases it around 15 seconds later and it goes back to 10.1.105.100.
Since I see it in env_vars, I figured I'd delete this file but even
after doing so, erasing the startup file and reloading, the value of
this variable was restored in the new Env_vars file. Can you tell me
where this info is stored?
From: Uli Link on
bobneworleans(a)yahoo.com schrieb:

> I'm working with a 1231 AP. I had addressed the BVI1 interface as
> 10.1.105.100 as a temporary work-around while DHCP was down. Now
> after rebooting the AP, DHCP gives it a valid lease but the AP
> releases it around 15 seconds later and it goes back to 10.1.105.100.
> Since I see it in env_vars, I figured I'd delete this file but even
> after doing so, erasing the startup file and reloading, the value of
> this variable was restored in the new Env_vars file. Can you tell me
> where this info is stored?

A safe and supported/documented way is
- to reset the AP using the mode button
- to reset via the web interface
and then a complete reconfigure.

If you update the configuration of interface BVI1 and then store the
configuration, the addresses in env_var should be updated to the new config.

--
ULi
From: bobneworleans on
On Jul 8, 3:42 pm, Uli Link <VonRechts.NachLi...(a)usenet.arcornews.de>
wrote:
> bobneworle...(a)yahoo.com schrieb:
>
> > I'm working with a 1231 AP.  I had addressed the BVI1 interface as
> > 10.1.105.100 as a temporary work-around while DHCP was down.  Now
> > after rebooting the AP, DHCP gives it a valid lease but the AP
> > releases it around 15 seconds later and it goes back to 10.1.105.100.
> > Since I see it in env_vars, I figured I'd delete this file but even
> > after doing so, erasing the startup file and reloading, the value of
> > this variable was restored in the new Env_vars file.  Can you tell me
> > where this info is stored?
>
> A safe and supported/documented way is
>   - to reset the AP using the mode button
>   - to reset via the web interface
> and then a complete reconfigure.
>
> If you update the configuration of interface BVI1 and then store the
> configuration, the addresses in env_var should be updated to the new config.
>
> --
> ULi

I reset and downloaded a fresh copy of IOS from tftp at 10.0.0.2.
This solved the problem but in a very inefficient manner.
I had hoped to learn a bit more about where this variable is stored
across reboots when neither env_vars nor the startup config are
present.