GUY! I am sorry to hear your plight and the amount of work you put into
this! This is precisely what excellent mailing lists like this are for.
We could have saved you hours and hours worth of work.
Take a look at:
(at the bottom, there is a link to the full, current config.xml)
This will let you download the full, current config.xml which can be
saved, and then uploaded to a new box with a working floppy.
Reverse Polarity, LLC
Guy Widloecher wrote:
> I have been confronted with the following problem: after a diskette failure,
> the m0n0wall was no longer manageable and the backup of config.xml was not
> up to date!
> Fortunately I could still connect at https://m0n0wall/exec.php. As I didn't
> find any information on the web, here's what I did:
> On the exec.php page, type the command "cat /tmp/config.cache" (of course,
> do not something like cat /conf/config.xml, it doesn't work because the
> diskette is broken)
> Put its content (a single line) in a file nammed config.cache (I used vi,
> gedit has some trouble with this very long line of text, I don't test with
> other editors).
> In the same folder, write the following php script :
> $config = unserialize(file_get_contents("config.cache"));
> $xmlconfig = dump_xml_config($config, $g['xml_rootobj']);
> echo var_dump($xmlconfig);
> echo "\n";
> Name this script prog.php
> Recover the files globals.inc, util.inc and xmlparse.inc from another
> m0n0wall running the same version or from the corresponding rootfs
> distribution. You should have in the folder : config.cache, prog.php,
> globals.inc, util.inc and xmlparse.inc.
> Run the php script: $ php prog.php
> If everything goes well, you must retrieve the file config.xml.
> I hope that this mini-howto may help somebody encountering the same problem.
> Best regards,
> Guy Widloecher