[clug] Software ergonomics
Jason Ozolins
jason.ozolins at anu.edu.au
Tue Jan 27 09:12:38 MST 2015
On 28/01/2015 1:11, Bryan Kilgallin wrote:
> Understanding SIOCADDRT: File exists Message
>
> 1. SIOC: *S*erial *I*nput *O*utput *C*ontroller.
> 2. ADD: *ADD* (addition).
> 3. RT: *R*ou*T*e (routing ip).
> 4. File exists - Routing is already configured so delete wrong one and
> add the new one.}
>
> http://www.cyberciti.biz/faq/siocaddrt-file-exists-ubuntu-linux-error-solution/
'Serial I/O Controller' is not an accurate explanation. SIOCADDRT is
one of many "socket I/O commands" that you can issue in an ioctl()
system call. You can see the whole gory list here:
http://lxr.free-electrons.com/source/include/uapi/linux/sockios.h#L28
The error code is a bit of a hack. You see, the ioctl() system call can
do a huge number of different things depending on what object is
attached to the file descriptor you call it on, and what command you
issue. But there are only a fixed number of errno error values. So
they get re-used with different nuance depending on the object that is
being operated on. And the people who wrote the "route" command just
expanded the error return code using the generic messages. It just so
happens that the "File exists" error code is what is returned from the
ioctl system call for the SIOCADDRT operation if there's an existing
route that clashes with the one you're trying to add.
> My concern here is for software ergonomics or human interface design. I
> have experience of reporting FISH shell documentation errors to people
> maintaining that.
>
> As explained above that error message means as follows.
> "The serial input/output controller advises that the address route you
> tried to add was already configured! So it suggests you delete the wrong
> address and add a new one."
>
> Instead, the user was actually told "SIOCADDRT: File exists". Which
> seems much less human-comprehensible!
>
> Can anyone here advise where (forum/e-mail) I might lodge lodge such a
> complaint with a relevant authority? Perhaps I might pass on a user
> suggestion to the relevant maintainers. I think it would be nice to be
> able to switch error reporting to verbose!
If you want this to change, you'd have to start a conversation with the
people who maintain the route program. On a box with RPM, you could type:
[jao900 at raijin3 ~]$ rpm -qf `which route`
net-tools-1.60-110.el6_2.x86_64
[jao900 at raijin3 ~]$ rpm -qi net-tools
Name : net-tools Relocations: (not relocatable)
Version : 1.60 Vendor: CentOS
[...]
URL : http://net-tools.berlios.de/
So you could head to that URL and see if there's a mailing list. Unless
you want to submit a patch to the 'route' source code yourself I doubt
that you'd get much traction with the developers. Even if you do submit
a patch, it's anyone's guess whether it will get integrated and make it
into a released binary...
Most people don't type route commands that often, and of those that do,
a lot of them know or guess what the error means. Not being rude here,
just... pragmatic.
-Jason
More information about the linux
mailing list