#Making /sys writable by users in wheel group? (without sudo)

1 messages · Page 1 of 1 (latest)

latent chasm
#

For example I want to make /sys/bus/platform/drivers/ideapad_acpi/VPC2004:00/conservation_mode writable, so I can

echo 1 > /sys/bus/platform/drivers/ideapad_acpi/VPC2004:00/conservation_mode```
instead of having to
```sh
echo 1 | sudo tee /sys/bus/platform/drivers/ideapad_acpi/VPC2004:00/conservation_mode```
#

With sudo I would receive a password prompt, while without sudo it would guarantee it's runnable by other applications running as that user

desert hedge
#

how about chown root:wheel and chmod 775

hollow karma
latent chasm
#

yeah, that's what I thought

#

but it should be possible if I run chown and chmod each boot?

#

nvm, operation not permitted

hollow karma
desert hedge
#

maybe you can google "how to chown /sys" and there will be more answers

hollow karma
latent chasm
#

huh? But i cant

hollow karma
# latent chasm huh? But i cant

We have similar laptops as my battery also has this interface.

We have similar laptops as my battery also has this interface.

latent chasm
#

oh wait smh

#

I forgot sudo 😂

#

still can't write to it tho

hollow karma
latent chasm
#

I may not be understanding perms correctly

hollow karma
latent chasm
#

oh wait, isn't it because of parent folders having root perms?

#

damn

hollow karma
latent chasm
#

Oh, that worked!

#

right, I see now

hollow karma
latent chasm
#

there was no write permission on the second user after : (wheel in my case)

hollow karma
#

These concepts are related, but they are not the same

latent chasm
#

is first "user" a specific user? or can it be a group too?

latent chasm
#

so, it may be a group too, but it's like the owner, right?

hollow karma
#

ðe permission bits are

rw- |rw-  |r--
root|wheel|all other users
latent chasm
#

Hmm ok, but then I'm kinda confused, what is chown for?

#

oh wait

hollow karma
latent chasm
#

chown group1:group2 file

rw- |rw-  |r--
group1|group2|all other users
#

is that right?

hollow karma
latent chasm
#

ok

#

good point

hollow karma
#

As mentioned above, the format is user|group|other.