Edit menu webinterface

Fritsy

Neuer User
Mitglied seit
3 Nov 2008
Beiträge
21
Punkte für Reaktionen
0
Punkte
0
Hello,

I would like to edit the menu structure of the webinterface of the Fritz!Box 7170.
When i edit a file in the /usr/www/avme/en/html/ directory i get an errormessage: File is read only

How can i edit these files or change the file permissions?

Thanks in advance! :)
 

MaxMuster

IPPF-Promi
Mitglied seit
1 Feb 2005
Beiträge
6,932
Punkte für Reaktionen
3
Punkte
38
As you just learned ;-): All files are stored in a read-only flash filesystem. Yon can not directly alter them.
Nevertheless there are two possible ways to change the pages:
First you can copy a page into the "RAM disk" of the box, change the file and mount it over the existing page e.g.:
Code:
cp /usr/www/avme/en/html/index.html /var/tmp/
mount -o bind /var/tmp/index.html /usr/www/avme/en/html/index.html
# now you may edit /var/tmp/index.html and you will see the result in /usr/www/avme/en/html/index.html
# you can also load prepared pages or even directories to the box and then mount them over existing ones
You may make these changes "semi permanent" by putting the necessary steps in the script /var/flash/debug.cfg.

The second possibility is to do permanent changes to the HTML pages by generating a modified firmware with the changed pages (e.g. with "freetz").

Jöerg
 

Joe_57

IPPF-Promi
Mitglied seit
5 Mrz 2006
Beiträge
6,337
Punkte für Reaktionen
199
Punkte
63
Hi Fritsy!

by using the followig commands you can determine the correct locations for the files used by the web interface:
Code:
cd /usr/www/html/html
pwd
This will show the path depending on the branding of the box.
Therefor I woud prefer using the following command to place a copy of the desired file to the tmp directory. :rolleyes:
Code:
cat /usr/www/html/html/index.html > /var/tmp/indes.html

Joe
 
Zuletzt bearbeitet:

Fritsy

Neuer User
Mitglied seit
3 Nov 2008
Beiträge
21
Punkte für Reaktionen
0
Punkte
0
The second possibility is to do permanent changes to the HTML pages by generating a modified firmware with the changed pages (e.g. with "freetz").

Thanks, i tried to copy, edit and mount the files and that sort of worked but it would be a lot better if i could create a complete firmware image that contains the changed pages.
I installed freetz but that doesn't do the trick for me. Is there an easier (or better) way to create the firmware image?
 

MaxMuster

IPPF-Promi
Mitglied seit
1 Feb 2005
Beiträge
6,932
Punkte für Reaktionen
3
Punkte
38
You can use freetz just to modify your image, as described in [How-To] Manuell Firmware entpacken, modifizieren, packen in german but I think should be straight forward.

Unpack your image with
Code:
./fwmod -u -d <unpacked_folder> <original FRITZ.Box.image>

Modify the pages in "<unpacked_folder>/original/filesystem "

repack your new firmware with

Code:
./fwmod -p -d <unpacked_folder> <original FRITZ.Box.image>
(yes, you will need the original firmware file name again, just a small drawback)

If you need to do this again, you must remove the "modified" folder before packing a new firmware or do your changes there instead....

Hope this helps.


Jörg
 
3CX

Neueste Beiträge

Statistik des Forums

Themen
239,537
Beiträge
2,129,051
Mitglieder
362,934
Neuestes Mitglied
Sempervivum
Erhalten Sie 3CX für 1 Jahr kostenlos!

Gehostet, in Ihrer privaten Cloud oder on-Premise! Ganz ohne Haken. Geben Sie Ihren Namen und Ihre E-Mail an und los geht´s:

3CX
Für diese E-Mail-Adresse besteht bereits ein 3CX-Konto. Sie werden zum Kundenportal weitergeleitet, wo Sie sich anmelden oder Ihr Passwort zurücksetzen können, falls Sie dieses vergessen haben.
oder via