1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Logging WAN-IP

Discussion in 'Tomato Firmware' started by willi007, Nov 26, 2007.

  1. willi007

    willi007 LI Guru Member

    Hi, with the tomato 1.11.1217 the logfile do not register the new wan-ip after a reconnect. Please, what shell I do?
    And: What are the different between the "loglevels"?
    Thanks a lot
  2. mstombs

    mstombs Network Guru Member

    You just need to paste something like this in the WANUP or firewall script:-
    logger "WANUP: New IP address is $(nvram get wan_ipaddr)"
  3. willi007

    willi007 LI Guru Member

    Many thanks!
  4. mstombs

    mstombs Network Guru Member

    Your welcome!

    I also had a look at the 'Console log level' in 'Administration - debugging' It seems this is a number 1-8 in the gui and busybox code but I can't find the exact definition - there's a dozen copies of syslog.h in the source code tools one of which suggests

     * priorities (these are ordered)
    #define	LOG_EMERG	0	/* system is unusable */
    #define	LOG_ALERT	1	/* action must be taken immediately */
    #define	LOG_CRIT	2	/* critical conditions */
    #define	LOG_ERR		3	/* error conditions */
    #define	LOG_WARNING	4	/* warning conditions */
    #define	LOG_NOTICE	5	/* normal but significant condition */
    #define	LOG_INFO	6	/* informational */
    #define	LOG_DEBUG	7	/* debug-level messages */
    error by 1 is one of the most common errors...

Share This Page