Make newnode scripts work on Linux
FreeBSD network devices are named after the device driver used, whereas Linux network devices are named after the interface type, such as 'eth0' for the first ethernet interface. The newclient script would send each interface name to the server via the 'ifacenameX' parameter, and newnodecheckin.php would use it to get the driver type for the interface. This works with the FreeBSD MFS, but not with the Linux one. Without this fix, all reported interfaces would be of type 'eth', which isn't helpful. To fix this, a new parameter was added to newnodecheckin.php called 'ifacedriverX' (where X is the interface number). This parameter is optional for backward compatibility with existing newnode MFS images. If present, it is used to specify the interface type. If not, the ifacenameX parameter is munged as before to extract the interface type. The newclient script reports this parameter under both FreeBSD and Linux. On FreeBSD, the interface name is munged to extract the t...
Showing with 43 additions and 5 deletions