You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@trafficserver.apache.org by "Mladen Turk (JIRA)" <ji...@apache.org> on 2010/05/17 07:34:41 UTC

[jira] Created: (TS-355) Autodetect default network interface

Autodetect default network interface
------------------------------------

                 Key: TS-355
                 URL: https://issues.apache.org/jira/browse/TS-355
             Project: Traffic Server
          Issue Type: New Feature
          Components: Build
            Reporter: Mladen Turk
            Assignee: Mladen Turk
            Priority: Minor


Currently we instruct the user to specify the cluster interface as part of build procedure (see INSTALL)
We can detect the interface automatically on some platforms
Linux
/sbin/ifconfig -a | grep ^e.* | head -1 | awk '{print $1;}'
Solaris, FreeBsd (probably OSX)
/sbin/ifconfig -a | grep -v LOOPBACK | grep UP | head -1 | awk -F: '{print $1;}'

Additional configure option (--with-cluster-interface=IFACE) can be added to explicitly
specify some other interface.


-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Closed: (TS-355) Autodetect default network interface

Posted by "Leif Hedstrom (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/TS-355?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Leif Hedstrom closed TS-355.
----------------------------

    Resolution: Fixed

it looks like this logic is already in the autoconf system (to pick a "reasonable" default interface), so closing this for now. I'll work on TS-327 and see if we can get a little better feedback there on failures.

> Autodetect default network interface
> ------------------------------------
>
>                 Key: TS-355
>                 URL: https://issues.apache.org/jira/browse/TS-355
>             Project: Traffic Server
>          Issue Type: New Feature
>          Components: Build
>            Reporter: Mladen Turk
>            Assignee: Mladen Turk
>            Priority: Critical
>             Fix For: 2.1.3
>
>   Original Estimate: 24h
>  Remaining Estimate: 24h
>
> Currently we instruct the user to specify the cluster interface as part of build procedure (see INSTALL)
> We can detect the interface automatically on some platforms
> Linux
> /sbin/ifconfig -a | grep ^e.* | head -1 | awk '{print $1;}'
> Solaris, FreeBsd (probably OSX)
> /sbin/ifconfig -a | grep -v LOOPBACK | grep UP | head -1 | awk -F: '{print $1;}'
> Additional configure option (--with-cluster-interface=IFACE) can be added to explicitly
> specify some other interface.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (TS-355) Autodetect default network interface

Posted by "Leif Hedstrom (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/TS-355?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Leif Hedstrom updated TS-355:
-----------------------------

    Fix Version/s: 2.1.2

> Autodetect default network interface
> ------------------------------------
>
>                 Key: TS-355
>                 URL: https://issues.apache.org/jira/browse/TS-355
>             Project: Traffic Server
>          Issue Type: New Feature
>          Components: Build
>            Reporter: Mladen Turk
>            Assignee: Mladen Turk
>            Priority: Minor
>             Fix For: 2.1.2
>
>   Original Estimate: 24h
>  Remaining Estimate: 24h
>
> Currently we instruct the user to specify the cluster interface as part of build procedure (see INSTALL)
> We can detect the interface automatically on some platforms
> Linux
> /sbin/ifconfig -a | grep ^e.* | head -1 | awk '{print $1;}'
> Solaris, FreeBsd (probably OSX)
> /sbin/ifconfig -a | grep -v LOOPBACK | grep UP | head -1 | awk -F: '{print $1;}'
> Additional configure option (--with-cluster-interface=IFACE) can be added to explicitly
> specify some other interface.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (TS-355) Autodetect default network interface

Posted by "Leif Hedstrom (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/TS-355?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Leif Hedstrom updated TS-355:
-----------------------------

    Priority: Critical  (was: Minor)

> Autodetect default network interface
> ------------------------------------
>
>                 Key: TS-355
>                 URL: https://issues.apache.org/jira/browse/TS-355
>             Project: Traffic Server
>          Issue Type: New Feature
>          Components: Build
>            Reporter: Mladen Turk
>            Assignee: Mladen Turk
>            Priority: Critical
>             Fix For: 2.1.2
>
>   Original Estimate: 24h
>  Remaining Estimate: 24h
>
> Currently we instruct the user to specify the cluster interface as part of build procedure (see INSTALL)
> We can detect the interface automatically on some platforms
> Linux
> /sbin/ifconfig -a | grep ^e.* | head -1 | awk '{print $1;}'
> Solaris, FreeBsd (probably OSX)
> /sbin/ifconfig -a | grep -v LOOPBACK | grep UP | head -1 | awk -F: '{print $1;}'
> Additional configure option (--with-cluster-interface=IFACE) can be added to explicitly
> specify some other interface.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (TS-355) Autodetect default network interface

Posted by "Leif Hedstrom (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/TS-355?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12909857#action_12909857 ] 

Leif Hedstrom commented on TS-355:
----------------------------------

I noticed that above is in the autoconf code right now, are we happy with that as a reasonable "solution" ? Since we do provide a default now, based on the build box environment,  it's kind of a moot point to try to "guess" at run-time, so maybe just fix TS-327 instead (to have better errors when the interface is wrong). 

Also, I'm wondering if something like this (on linux at least) would make more sense:

/sbin/ip route |  awk '/default/ {print $5}


That makes the default interface in the config be the same interface as used for the default route on the build box. It still has the same issue as mentioned above though.

> Autodetect default network interface
> ------------------------------------
>
>                 Key: TS-355
>                 URL: https://issues.apache.org/jira/browse/TS-355
>             Project: Traffic Server
>          Issue Type: New Feature
>          Components: Build
>            Reporter: Mladen Turk
>            Assignee: Mladen Turk
>            Priority: Critical
>             Fix For: 2.1.3
>
>   Original Estimate: 24h
>  Remaining Estimate: 24h
>
> Currently we instruct the user to specify the cluster interface as part of build procedure (see INSTALL)
> We can detect the interface automatically on some platforms
> Linux
> /sbin/ifconfig -a | grep ^e.* | head -1 | awk '{print $1;}'
> Solaris, FreeBsd (probably OSX)
> /sbin/ifconfig -a | grep -v LOOPBACK | grep UP | head -1 | awk -F: '{print $1;}'
> Additional configure option (--with-cluster-interface=IFACE) can be added to explicitly
> specify some other interface.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (TS-355) Autodetect default network interface

Posted by "Leif Hedstrom (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/TS-355?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12868261#action_12868261 ] 

Leif Hedstrom commented on TS-355:
----------------------------------

We should fix this together with TS-327 as well. Meaning, we should handle the 'wrong' setting better as well.

> Autodetect default network interface
> ------------------------------------
>
>                 Key: TS-355
>                 URL: https://issues.apache.org/jira/browse/TS-355
>             Project: Traffic Server
>          Issue Type: New Feature
>          Components: Build
>            Reporter: Mladen Turk
>            Assignee: Mladen Turk
>            Priority: Minor
>   Original Estimate: 24h
>  Remaining Estimate: 24h
>
> Currently we instruct the user to specify the cluster interface as part of build procedure (see INSTALL)
> We can detect the interface automatically on some platforms
> Linux
> /sbin/ifconfig -a | grep ^e.* | head -1 | awk '{print $1;}'
> Solaris, FreeBsd (probably OSX)
> /sbin/ifconfig -a | grep -v LOOPBACK | grep UP | head -1 | awk -F: '{print $1;}'
> Additional configure option (--with-cluster-interface=IFACE) can be added to explicitly
> specify some other interface.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (TS-355) Autodetect default network interface

Posted by "Mladen Turk (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/TS-355?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12868125#action_12868125 ] 

Mladen Turk commented on TS-355:
--------------------------------

More correct Linux script
/sbin/ifconfig | sed 's/^ *$/CRLF/g' | tr '\n' ' ' | sed 's/CRLF /\n/g' | grep -v LOOPBACK | grep 'UP.*RUNNING' | head -1 | awk '{print $1;}'
Complex because info spreads across multiple lines, so we create one line for each iface block and then grep 

For Solaris, BSD, Mac
/sbin/ifconfig -a | grep 'UP.*RUNNING' | grep -v LOOPBACK | head -1 | awk -F: '{ print $1;}'



> Autodetect default network interface
> ------------------------------------
>
>                 Key: TS-355
>                 URL: https://issues.apache.org/jira/browse/TS-355
>             Project: Traffic Server
>          Issue Type: New Feature
>          Components: Build
>            Reporter: Mladen Turk
>            Assignee: Mladen Turk
>            Priority: Minor
>   Original Estimate: 24h
>  Remaining Estimate: 24h
>
> Currently we instruct the user to specify the cluster interface as part of build procedure (see INSTALL)
> We can detect the interface automatically on some platforms
> Linux
> /sbin/ifconfig -a | grep ^e.* | head -1 | awk '{print $1;}'
> Solaris, FreeBsd (probably OSX)
> /sbin/ifconfig -a | grep -v LOOPBACK | grep UP | head -1 | awk -F: '{print $1;}'
> Additional configure option (--with-cluster-interface=IFACE) can be added to explicitly
> specify some other interface.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.