scp of sysfs file repeats data

Craig McQueen craig.mcqueen at innerrange.com
Tue Jun 23 12:10:49 AWST 2015


> Subject: scp of sysfs file repeats data
> 
> I tried doing scp of a sysfs attribute. I found that it duplicated the data, as
> well as adding extra NUL bytes. E.g.:
> 
> # scp /sys/class/net/eth0/address localhost:
> # cat ~/address
> d0:39:72:53:ef:0e
> d0:39:72:53:ef:0e
> # hexdump -C ~/address
> 00000000  64 30 3a 33 39 3a 37 32  3a 35 33 3a 65 66 3a 30  |d0:39:72:53:ef:0|
> 00000010  65 0a 00 00 00 00 00 00  00 00 00 00 00 00 00 00  |e...............|
> 00000020  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  |................|
> *
> 00000800  64 30 3a 33 39 3a 37 32  3a 35 33 3a 65 66 3a 30  |d0:39:72:53:ef:0|
> 00000810  65 0a 00 00 00 00 00 00  00 00 00 00 00 00 00 00  |e...............|
> 00000820  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  |................|
> *
> 00001000
> 
> Does that seem normal?

By the way, this is on a BeagleBone Black-based (ARM Cortex) Linux system built with Yocto dizzy.



More information about the Dropbear mailing list