# Cant "wget" Update modules, permission denied

**URL:** <https://hub.mender.io/t/cant-wget-update-modules-permission-denied/6085>\
**Category:** General Discussions\
**Created:** [August 7, 2023, 9:45am UTC](https://hub.mender.io/t/cant-wget-update-modules-permission-denied/6085 "2023-08-07T09:45:57Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![fbaer](https://avatars.discourse-cdn.com/v4/letter/f/34f0e0/32.png) [@fbaer](https://hub.mender.io/u/fbaer)\
**Post date:** [August 7, 2023, 9:45am UTC](https://hub.mender.io/t/cant-wget-update-modules-permission-denied/6085/1 "2023-08-07T09:45:57Z")

</div>

Hello everyone,  
i’ve got the problem i can’t “install” a single update Module.  
I’ve tried for example: `mkdir -p /usr/share/mender/modules/v3 && wget -P /usr/share/mender/modules/v3 https://raw.githubusercontent.com/mendersoftware/mender/master/tests/rootfs-image-v2 `  
And got

```auto
--2023-08-07 10:44:26-- https://raw.githubusercontent.com/mendersoftware/mender/master/tests/rootfs-image-v2
Resolving raw.githubusercontent.com (raw.githubusercontent.com)... 185.199.111.133, 185.199.108.133, 185.199.109.133, ...
Connecting to raw.githubusercontent.com (raw.githubusercontent.com)|185.199.111.133|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 2932 (2.9K) [text/plain]
/usr/share/mender/modules/v3/rootfs-image-v2: Permission denied

Cannot write to ‘/usr/share/mender/modules/v3/rootfs-image-v2’ (Permission denied).

```

I’m totally new to Mender as well as any Linux OS.

Hope you can help me in any kind of way.

Kind Regards  
Florian.

---

<div class="post-metadata">

**Author:** ![arp\_insens](https://avatars.discourse-cdn.com/v4/letter/a/eada6e/32.png) [@arp\_insens](https://hub.mender.io/u/arp_insens)\
**Post date:** [August 7, 2023, 10:02am UTC](https://hub.mender.io/t/cant-wget-update-modules-permission-denied/6085/2 "2023-08-07T10:02:51Z")

</div>

hello,  
permission denied is because your Linux user does nos have sudo privilege ([Linux sudo commands for beginners](https://www.pluralsight.com/resources/blog/cloud/linux-commands-for-beginners-sudo))  
use sudo before your command and it should work 🙂

---

<div class="post-metadata">

**Author:** ![fbaer](https://avatars.discourse-cdn.com/v4/letter/f/34f0e0/32.png) [@fbaer](https://hub.mender.io/u/fbaer)\
**Post date:** [August 7, 2023, 10:12am UTC](https://hub.mender.io/t/cant-wget-update-modules-permission-denied/6085/3 "2023-08-07T10:12:13Z")

</div>

I would love to say it worked, but it didn’t. Even with sudo.  
Getting exact the same Error.  
But i was able to manage it. For some reason the directory was read only.  
i used:

```auto
sudo chmod ...

```

to set it also for writing and then your sudo command worked just fine. TY

---

<div class="post-metadata">

**Author:** ![arp\_insens](https://avatars.discourse-cdn.com/v4/letter/a/eada6e/32.png) [@arp\_insens](https://hub.mender.io/u/arp_insens)\
**Post date:** [August 7, 2023, 10:30am UTC](https://hub.mender.io/t/cant-wget-update-modules-permission-denied/6085/4 "2023-08-07T10:30:35Z")

</div>

@fbaer It’s recommended to maintain the directory’s permissions as they are, even if you’re the only one accessing the device. Keeping sensitive files and folders in secure read-only mode is good practice.

In the shell, ‘&&’ is a separator that you can interpret as ‘and,’ so you need to re-use the ‘sudo’ on the second command as well.

---

<div class="post-metadata">

**Author:** ![fbaer](https://avatars.discourse-cdn.com/v4/letter/f/34f0e0/32.png) [@fbaer](https://hub.mender.io/u/fbaer)\
**Post date:** [August 7, 2023, 11:12am UTC](https://hub.mender.io/t/cant-wget-update-modules-permission-denied/6085/5 "2023-08-07T11:12:00Z")

</div>

Even better. TY
