Question

I am trying to write a block device driver that reads/writes off of the network. In essence, I have modified the example here for ram disks. And Here is my code. When I try to write to the block device using the command sudo cat > /dev/rb, I get premission denied.

$ sudo cat > /dev/rb
bash: /dev/rb: Permission denied

Can Anyone help me fix this??

I can see nothing suspicious in the kernel log.

Thanks in advance!

Was it helpful?

Solution

Your redirection is not run as root, only cat does.

Try the following:

sudo sh
# cat > /dev/rb

Once it works, combine into a single command line (most probably: sudo "cat > /dev/rb")

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top