# Issue with tuntap\_pdu

**URL:** <https://www.ruby-forum.com/t/issue-with-tuntap-pdu/232957>\
**Category:** GNU Radio\
**Created:** [November 7, 2014, 12:42am UTC](https://www.ruby-forum.com/t/issue-with-tuntap-pdu/232957 "2014-11-07T00:42:25Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![addis\_a](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/c4cdca/32.png) [@addis\_a](https://www.ruby-forum.com/u/addis_a)\
**Post date:** [November 7, 2014, 12:42am UTC](https://www.ruby-forum.com/t/issue-with-tuntap-pdu/232957/1 "2014-11-07T00:42:25Z")

</div>

I am trying to run the example simple\_trx.py script from the gr-mac  
module  
and I am having an issue related to what I believe is  
gr::blocks::tuntap\_pdu.

This is what I am doing.

I open up a couple of terminal windows and in two of them I place in  
these  
separate commands.

[root@xxxx project]# ./simple\_trx.py --radio-addr 85 --dest-addr 86  
–port  
12345 -a addr=10.2.8.104

[root@xxxx project]# ./simple\_trx.py --radio-addr 86 --dest-addr 85  
–port  
12346 -a addr=10.2.8.105

The former will run just fine and then the second one gives me this  
error

[root@xxxx project]# ./simple\_trx.py --radio-addr 86 --dest-addr 85  
–port  
12346 -a addr=10.2.8.105  
linux; GNU C++ version 4.4.7 20120313 (Red Hat 4.4.7-4); Boost\_104100;  
UHD\_003.007.001-64-g92b0b7ab

libGL error: failed to load driver: nouveau  
libGL error: Try again with LIBGL\_DEBUG=verbose for more details.  
Using Volk machine: sse4\_2\_64  
Simple MAC ARQ in non-blocking mode  
\<virtual\_channel\_encoder[25]\> MTU: 128  
‘post\_msg’ not found. Using ‘message\_port\_pub’ instead.  
Virtual channel encoder in non-blocking mode  
\<virtual\_channel\_encoder[26]\> MTU: 128  
‘post\_msg’ not found. Using ‘message\_port\_pub’ instead.  
Virtual channel encoder in non-blocking mode  
– Opening a USRP2/N-Series device…  
– Current recv frame size: 1472 bytes  
– Current send frame size: 1472 bytes  
– Detecting internal GPSDO… Found an internal GPSDO  
– found  
– Setting references to the internal GPSDO  
– Initializing time to the internal GPSDO  
\<burst\_tagger[36]\> tag name: length, multiplier: 32.000000, tag front:  
0,  
tag rear: 16, drop residue: yes, verbose: yes  
bits per symbol = 1  
M&M clock recovery omega = 4.000000  
M&M clock recovery gain mu = 0.175000  
M&M clock recovery mu = 0.500000  
M&M clock recovery omega rel. limit = 0.005000  
frequency error = 0.000000  
Traceback (most recent call last):  
File “./simple\_trx.py”, line 386, in   
tb = simple\_trx(args=options.args,  
tx\_lo\_offset=options.tx\_lo\_offset,  
rx\_lo\_offset=options.rx\_lo\_offset, rate=options.rate,  
rx\_antenna=options.rx\_antenna, rx\_freq=options.rx\_freq,  
tx\_freq=options.tx\_freq, rx\_gain=options.rx\_gain,  
tx\_gain=options.tx\_gain,  
samps\_per\_sym=options.samps\_per\_sym, ampl=options.ampl,  
arq\_timeout=options.arq\_timeout, dest\_addr=options.dest\_addr,  
max\_arq\_attempts=options.max\_arq\_attempts,  
radio\_addr=options.radio\_addr,  
iface=options.iface, mtu=options.mtu, port=options.port)  
File “./simple\_trx.py”, line 157, in **init**  
self.blocks\_tuntap\_pdu\_0 = blocks.tuntap\_pdu(iface, mtu\*0 + 1514)  
File  
“/usr/local/lib64/python2.6/site-packages/gnuradio/blocks/blocks\_swig5.py”,  
line 1796, in make  
return \_blocks\_swig5.tuntap\_pdu\_make(\*args, \*\*kwargs)  
RuntimeError: gr::tuntap\_pdu::make: tun\_alloc failed (are you running as  
root?)

Of course I am running this as root. Why can’t I have two instances of  
this  
running?

Jonathan F.

---

<div class="post-metadata">

**Author:** ![jfaulkenberry](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/c2a13f/32.png) [@jfaulkenberry](https://www.ruby-forum.com/u/jfaulkenberry)\
**Post date:** [November 10, 2014, 6:08pm UTC](https://www.ruby-forum.com/t/issue-with-tuntap-pdu/232957/2 "2014-11-10T18:08:23Z")

</div>

On Thu, Nov 6, 2014 at 6:41 PM, Jonathan F.  
[removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)  
wrote:

> –port 12345 -a addr=10.2.8.104
> 
> – Opening a USRP2/N-Series device…  
> M&M clock recovery gain mu = 0.175000  
> arq\_timeout=options.arq\_timeout, dest\_addr=options.dest\_addr,
> 
> Of course I am running this as root. Why can’t I have two instances of  
> this running?
> 
> Jonathan F.

Alright figured out my issue.

I needed to specify a different interface for the second instance of  
simple\_trx so I couldn’t let it default to “tun0” so I specified it as  
“tun1”.

Jonathan F.
