Permission denied in rc.local
Here's the contents of my /etc/rc.local
/etc/pm/power.d/99macbookair6 true
echo 0 > /sys/module/hid_apple/parameters/iso_layout
exit 0
running
service rc.local start
returns
/etc/rc.local: 14: /etc/rc.local: /etc/pm/power.d/99macbookair6: Permission denied
14.04 scripts services
add a comment |
Here's the contents of my /etc/rc.local
/etc/pm/power.d/99macbookair6 true
echo 0 > /sys/module/hid_apple/parameters/iso_layout
exit 0
running
service rc.local start
returns
/etc/rc.local: 14: /etc/rc.local: /etc/pm/power.d/99macbookair6: Permission denied
14.04 scripts services
1
You need to run it withsudo
.
– edwinksl
Jul 24 '16 at 2:01
Thanks. However, it still doesn't run correctly on startup. Edit: Nevermind.
– half-potato
Jul 24 '16 at 2:08
add a comment |
Here's the contents of my /etc/rc.local
/etc/pm/power.d/99macbookair6 true
echo 0 > /sys/module/hid_apple/parameters/iso_layout
exit 0
running
service rc.local start
returns
/etc/rc.local: 14: /etc/rc.local: /etc/pm/power.d/99macbookair6: Permission denied
14.04 scripts services
Here's the contents of my /etc/rc.local
/etc/pm/power.d/99macbookair6 true
echo 0 > /sys/module/hid_apple/parameters/iso_layout
exit 0
running
service rc.local start
returns
/etc/rc.local: 14: /etc/rc.local: /etc/pm/power.d/99macbookair6: Permission denied
14.04 scripts services
14.04 scripts services
edited Jul 24 '16 at 1:59
edwinksl
16.5k125385
16.5k125385
asked Jul 24 '16 at 1:57
half-potato
11316
11316
1
You need to run it withsudo
.
– edwinksl
Jul 24 '16 at 2:01
Thanks. However, it still doesn't run correctly on startup. Edit: Nevermind.
– half-potato
Jul 24 '16 at 2:08
add a comment |
1
You need to run it withsudo
.
– edwinksl
Jul 24 '16 at 2:01
Thanks. However, it still doesn't run correctly on startup. Edit: Nevermind.
– half-potato
Jul 24 '16 at 2:08
1
1
You need to run it with
sudo
.– edwinksl
Jul 24 '16 at 2:01
You need to run it with
sudo
.– edwinksl
Jul 24 '16 at 2:01
Thanks. However, it still doesn't run correctly on startup. Edit: Nevermind.
– half-potato
Jul 24 '16 at 2:08
Thanks. However, it still doesn't run correctly on startup. Edit: Nevermind.
– half-potato
Jul 24 '16 at 2:08
add a comment |
2 Answers
2
active
oldest
votes
The portion of the error message you want to look at is:
/etc/pm/power.d/99macbookair6: Permission denied
which says you do not have sufficient permission to execute /etc/pm/power.d/99macbookair6
.
Even if you have some command here executable by you, you would still get permission denied error for:
echo 0 > /sys/module/hid_apple/parameters/iso_layout
In a nutshell, you can do:
service rc.local start
only when you have all entries in /etc/rc.local
executable by you (and also rc.local
must be readable by you obviously). Same goes for brothers of start
i.e. stop
, restart
etc.
To get your current setup working, the most sane way is to run the command as root
:
sudo service rc.local start
I did chmod 777 /etc/pm/power.d/99macbookair6
– half-potato
Jul 26 '16 at 20:20
add a comment |
The "Permission denied" message tells you that you lack sufficient privileges to execute the command. You need to run service rc.local start
with sudo
privileges:
sudo service rc.local start
add a comment |
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "89"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f802221%2fpermission-denied-in-rc-local%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
The portion of the error message you want to look at is:
/etc/pm/power.d/99macbookair6: Permission denied
which says you do not have sufficient permission to execute /etc/pm/power.d/99macbookair6
.
Even if you have some command here executable by you, you would still get permission denied error for:
echo 0 > /sys/module/hid_apple/parameters/iso_layout
In a nutshell, you can do:
service rc.local start
only when you have all entries in /etc/rc.local
executable by you (and also rc.local
must be readable by you obviously). Same goes for brothers of start
i.e. stop
, restart
etc.
To get your current setup working, the most sane way is to run the command as root
:
sudo service rc.local start
I did chmod 777 /etc/pm/power.d/99macbookair6
– half-potato
Jul 26 '16 at 20:20
add a comment |
The portion of the error message you want to look at is:
/etc/pm/power.d/99macbookair6: Permission denied
which says you do not have sufficient permission to execute /etc/pm/power.d/99macbookair6
.
Even if you have some command here executable by you, you would still get permission denied error for:
echo 0 > /sys/module/hid_apple/parameters/iso_layout
In a nutshell, you can do:
service rc.local start
only when you have all entries in /etc/rc.local
executable by you (and also rc.local
must be readable by you obviously). Same goes for brothers of start
i.e. stop
, restart
etc.
To get your current setup working, the most sane way is to run the command as root
:
sudo service rc.local start
I did chmod 777 /etc/pm/power.d/99macbookair6
– half-potato
Jul 26 '16 at 20:20
add a comment |
The portion of the error message you want to look at is:
/etc/pm/power.d/99macbookair6: Permission denied
which says you do not have sufficient permission to execute /etc/pm/power.d/99macbookair6
.
Even if you have some command here executable by you, you would still get permission denied error for:
echo 0 > /sys/module/hid_apple/parameters/iso_layout
In a nutshell, you can do:
service rc.local start
only when you have all entries in /etc/rc.local
executable by you (and also rc.local
must be readable by you obviously). Same goes for brothers of start
i.e. stop
, restart
etc.
To get your current setup working, the most sane way is to run the command as root
:
sudo service rc.local start
The portion of the error message you want to look at is:
/etc/pm/power.d/99macbookair6: Permission denied
which says you do not have sufficient permission to execute /etc/pm/power.d/99macbookair6
.
Even if you have some command here executable by you, you would still get permission denied error for:
echo 0 > /sys/module/hid_apple/parameters/iso_layout
In a nutshell, you can do:
service rc.local start
only when you have all entries in /etc/rc.local
executable by you (and also rc.local
must be readable by you obviously). Same goes for brothers of start
i.e. stop
, restart
etc.
To get your current setup working, the most sane way is to run the command as root
:
sudo service rc.local start
answered Jul 24 '16 at 3:27
heemayl
65.8k8137211
65.8k8137211
I did chmod 777 /etc/pm/power.d/99macbookair6
– half-potato
Jul 26 '16 at 20:20
add a comment |
I did chmod 777 /etc/pm/power.d/99macbookair6
– half-potato
Jul 26 '16 at 20:20
I did chmod 777 /etc/pm/power.d/99macbookair6
– half-potato
Jul 26 '16 at 20:20
I did chmod 777 /etc/pm/power.d/99macbookair6
– half-potato
Jul 26 '16 at 20:20
add a comment |
The "Permission denied" message tells you that you lack sufficient privileges to execute the command. You need to run service rc.local start
with sudo
privileges:
sudo service rc.local start
add a comment |
The "Permission denied" message tells you that you lack sufficient privileges to execute the command. You need to run service rc.local start
with sudo
privileges:
sudo service rc.local start
add a comment |
The "Permission denied" message tells you that you lack sufficient privileges to execute the command. You need to run service rc.local start
with sudo
privileges:
sudo service rc.local start
The "Permission denied" message tells you that you lack sufficient privileges to execute the command. You need to run service rc.local start
with sudo
privileges:
sudo service rc.local start
answered Jul 24 '16 at 2:02
edwinksl
16.5k125385
16.5k125385
add a comment |
add a comment |
Thanks for contributing an answer to Ask Ubuntu!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f802221%2fpermission-denied-in-rc-local%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
1
You need to run it with
sudo
.– edwinksl
Jul 24 '16 at 2:01
Thanks. However, it still doesn't run correctly on startup. Edit: Nevermind.
– half-potato
Jul 24 '16 at 2:08