How do I add a kernel boot parameter?
I need to add the boot parameter foo=bar
to my kernel. How can I do this once for testing, and permanently if testing was a success?
kernel grub2
add a comment |
I need to add the boot parameter foo=bar
to my kernel. How can I do this once for testing, and permanently if testing was a success?
kernel grub2
add a comment |
I need to add the boot parameter foo=bar
to my kernel. How can I do this once for testing, and permanently if testing was a success?
kernel grub2
I need to add the boot parameter foo=bar
to my kernel. How can I do this once for testing, and permanently if testing was a success?
kernel grub2
kernel grub2
edited Jan 20 '13 at 18:06
Jorge Castro
36k105422617
36k105422617
asked Dec 30 '10 at 22:51
htorquehtorque
46.9k32172212
46.9k32172212
add a comment |
add a comment |
3 Answers
3
active
oldest
votes
To temporarily add a boot parameter to a kernel:
- Start your system and wait for the GRUB menu to show (if you don't see a GRUB menu, press and hold the left Shift key right after starting the system).
- Now highlight the kernel you want to use, and press the e key. You should be able to see and edit the commands associated with the highlighted kernel.
- Go down to the line starting with
linux
and add your parameterfoo=bar
to its end. - Now press Ctrl + x to boot.
To make this change permanent:
From a terminal (or after pressing Alt + F2) run:
gksudo gedit /etc/default/grub
(or use
sudo nano
ifgksudo
orgedit
are not available) and enter your password.
Find the line starting with
GRUB_CMDLINE_LINUX_DEFAULT
and appendfoo=bar
to its end. For example:
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash foo=bar"
Save the file and close the editor.
Finally, start a terminal and run:
sudo update-grub
to update GRUB's configuration file (you probably need to enter your password).
On the next reboot, the kernel should be started with the boot parameter. To permanently remove it, simply remove the parameter from GRUB_CMDLINE_LINUX_DEFAULT
and run sudo update-grub
again.
To verify your changes, you can see exactly what parameters your kernel booted with by executing cat /proc/cmdline
.
Wiki Page:
- https://help.ubuntu.com/community/BootOptions
3
FYI to test this runcat /proc/cmdline
– Avindra Goolcharan
Aug 3 '16 at 15:13
Shift doesn’t work for me. I used Esc instead. Had to be careful not to hold it too long or it would blow right through GRUB
– eqzx
Jul 7 '18 at 3:18
add a comment |
To add any kernel option:
for a liveCD session: follow these steps
for an Existing Installation: use Boot-Repair's
Add a kernel option
orEdit GRUB configuration file
options.
See also this documentation.
add a comment |
Alternatively, you may also use the handy grub-customizer:
sudo add-apt-repository ppa:danielrichter2007/grub-customizer
sudo apt-get update
sudo apt-get install grub-customizer
gksu grub-customizer &
Just open a boot entry, and edit its kernel parameters as highlighted in the screenshot below:
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%2f19486%2fhow-do-i-add-a-kernel-boot-parameter%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
3 Answers
3
active
oldest
votes
3 Answers
3
active
oldest
votes
active
oldest
votes
active
oldest
votes
To temporarily add a boot parameter to a kernel:
- Start your system and wait for the GRUB menu to show (if you don't see a GRUB menu, press and hold the left Shift key right after starting the system).
- Now highlight the kernel you want to use, and press the e key. You should be able to see and edit the commands associated with the highlighted kernel.
- Go down to the line starting with
linux
and add your parameterfoo=bar
to its end. - Now press Ctrl + x to boot.
To make this change permanent:
From a terminal (or after pressing Alt + F2) run:
gksudo gedit /etc/default/grub
(or use
sudo nano
ifgksudo
orgedit
are not available) and enter your password.
Find the line starting with
GRUB_CMDLINE_LINUX_DEFAULT
and appendfoo=bar
to its end. For example:
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash foo=bar"
Save the file and close the editor.
Finally, start a terminal and run:
sudo update-grub
to update GRUB's configuration file (you probably need to enter your password).
On the next reboot, the kernel should be started with the boot parameter. To permanently remove it, simply remove the parameter from GRUB_CMDLINE_LINUX_DEFAULT
and run sudo update-grub
again.
To verify your changes, you can see exactly what parameters your kernel booted with by executing cat /proc/cmdline
.
Wiki Page:
- https://help.ubuntu.com/community/BootOptions
3
FYI to test this runcat /proc/cmdline
– Avindra Goolcharan
Aug 3 '16 at 15:13
Shift doesn’t work for me. I used Esc instead. Had to be careful not to hold it too long or it would blow right through GRUB
– eqzx
Jul 7 '18 at 3:18
add a comment |
To temporarily add a boot parameter to a kernel:
- Start your system and wait for the GRUB menu to show (if you don't see a GRUB menu, press and hold the left Shift key right after starting the system).
- Now highlight the kernel you want to use, and press the e key. You should be able to see and edit the commands associated with the highlighted kernel.
- Go down to the line starting with
linux
and add your parameterfoo=bar
to its end. - Now press Ctrl + x to boot.
To make this change permanent:
From a terminal (or after pressing Alt + F2) run:
gksudo gedit /etc/default/grub
(or use
sudo nano
ifgksudo
orgedit
are not available) and enter your password.
Find the line starting with
GRUB_CMDLINE_LINUX_DEFAULT
and appendfoo=bar
to its end. For example:
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash foo=bar"
Save the file and close the editor.
Finally, start a terminal and run:
sudo update-grub
to update GRUB's configuration file (you probably need to enter your password).
On the next reboot, the kernel should be started with the boot parameter. To permanently remove it, simply remove the parameter from GRUB_CMDLINE_LINUX_DEFAULT
and run sudo update-grub
again.
To verify your changes, you can see exactly what parameters your kernel booted with by executing cat /proc/cmdline
.
Wiki Page:
- https://help.ubuntu.com/community/BootOptions
3
FYI to test this runcat /proc/cmdline
– Avindra Goolcharan
Aug 3 '16 at 15:13
Shift doesn’t work for me. I used Esc instead. Had to be careful not to hold it too long or it would blow right through GRUB
– eqzx
Jul 7 '18 at 3:18
add a comment |
To temporarily add a boot parameter to a kernel:
- Start your system and wait for the GRUB menu to show (if you don't see a GRUB menu, press and hold the left Shift key right after starting the system).
- Now highlight the kernel you want to use, and press the e key. You should be able to see and edit the commands associated with the highlighted kernel.
- Go down to the line starting with
linux
and add your parameterfoo=bar
to its end. - Now press Ctrl + x to boot.
To make this change permanent:
From a terminal (or after pressing Alt + F2) run:
gksudo gedit /etc/default/grub
(or use
sudo nano
ifgksudo
orgedit
are not available) and enter your password.
Find the line starting with
GRUB_CMDLINE_LINUX_DEFAULT
and appendfoo=bar
to its end. For example:
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash foo=bar"
Save the file and close the editor.
Finally, start a terminal and run:
sudo update-grub
to update GRUB's configuration file (you probably need to enter your password).
On the next reboot, the kernel should be started with the boot parameter. To permanently remove it, simply remove the parameter from GRUB_CMDLINE_LINUX_DEFAULT
and run sudo update-grub
again.
To verify your changes, you can see exactly what parameters your kernel booted with by executing cat /proc/cmdline
.
Wiki Page:
- https://help.ubuntu.com/community/BootOptions
To temporarily add a boot parameter to a kernel:
- Start your system and wait for the GRUB menu to show (if you don't see a GRUB menu, press and hold the left Shift key right after starting the system).
- Now highlight the kernel you want to use, and press the e key. You should be able to see and edit the commands associated with the highlighted kernel.
- Go down to the line starting with
linux
and add your parameterfoo=bar
to its end. - Now press Ctrl + x to boot.
To make this change permanent:
From a terminal (or after pressing Alt + F2) run:
gksudo gedit /etc/default/grub
(or use
sudo nano
ifgksudo
orgedit
are not available) and enter your password.
Find the line starting with
GRUB_CMDLINE_LINUX_DEFAULT
and appendfoo=bar
to its end. For example:
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash foo=bar"
Save the file and close the editor.
Finally, start a terminal and run:
sudo update-grub
to update GRUB's configuration file (you probably need to enter your password).
On the next reboot, the kernel should be started with the boot parameter. To permanently remove it, simply remove the parameter from GRUB_CMDLINE_LINUX_DEFAULT
and run sudo update-grub
again.
To verify your changes, you can see exactly what parameters your kernel booted with by executing cat /proc/cmdline
.
Wiki Page:
- https://help.ubuntu.com/community/BootOptions
edited Jan 4 '18 at 15:16
Zanna
50.2k13133241
50.2k13133241
answered Dec 30 '10 at 22:51
htorquehtorque
46.9k32172212
46.9k32172212
3
FYI to test this runcat /proc/cmdline
– Avindra Goolcharan
Aug 3 '16 at 15:13
Shift doesn’t work for me. I used Esc instead. Had to be careful not to hold it too long or it would blow right through GRUB
– eqzx
Jul 7 '18 at 3:18
add a comment |
3
FYI to test this runcat /proc/cmdline
– Avindra Goolcharan
Aug 3 '16 at 15:13
Shift doesn’t work for me. I used Esc instead. Had to be careful not to hold it too long or it would blow right through GRUB
– eqzx
Jul 7 '18 at 3:18
3
3
FYI to test this run
cat /proc/cmdline
– Avindra Goolcharan
Aug 3 '16 at 15:13
FYI to test this run
cat /proc/cmdline
– Avindra Goolcharan
Aug 3 '16 at 15:13
Shift doesn’t work for me. I used Esc instead. Had to be careful not to hold it too long or it would blow right through GRUB
– eqzx
Jul 7 '18 at 3:18
Shift doesn’t work for me. I used Esc instead. Had to be careful not to hold it too long or it would blow right through GRUB
– eqzx
Jul 7 '18 at 3:18
add a comment |
To add any kernel option:
for a liveCD session: follow these steps
for an Existing Installation: use Boot-Repair's
Add a kernel option
orEdit GRUB configuration file
options.
See also this documentation.
add a comment |
To add any kernel option:
for a liveCD session: follow these steps
for an Existing Installation: use Boot-Repair's
Add a kernel option
orEdit GRUB configuration file
options.
See also this documentation.
add a comment |
To add any kernel option:
for a liveCD session: follow these steps
for an Existing Installation: use Boot-Repair's
Add a kernel option
orEdit GRUB configuration file
options.
See also this documentation.
To add any kernel option:
for a liveCD session: follow these steps
for an Existing Installation: use Boot-Repair's
Add a kernel option
orEdit GRUB configuration file
options.
See also this documentation.
answered Jul 5 '12 at 21:25
LovinBuntuLovinBuntu
2,84021519
2,84021519
add a comment |
add a comment |
Alternatively, you may also use the handy grub-customizer:
sudo add-apt-repository ppa:danielrichter2007/grub-customizer
sudo apt-get update
sudo apt-get install grub-customizer
gksu grub-customizer &
Just open a boot entry, and edit its kernel parameters as highlighted in the screenshot below:
add a comment |
Alternatively, you may also use the handy grub-customizer:
sudo add-apt-repository ppa:danielrichter2007/grub-customizer
sudo apt-get update
sudo apt-get install grub-customizer
gksu grub-customizer &
Just open a boot entry, and edit its kernel parameters as highlighted in the screenshot below:
add a comment |
Alternatively, you may also use the handy grub-customizer:
sudo add-apt-repository ppa:danielrichter2007/grub-customizer
sudo apt-get update
sudo apt-get install grub-customizer
gksu grub-customizer &
Just open a boot entry, and edit its kernel parameters as highlighted in the screenshot below:
Alternatively, you may also use the handy grub-customizer:
sudo add-apt-repository ppa:danielrichter2007/grub-customizer
sudo apt-get update
sudo apt-get install grub-customizer
gksu grub-customizer &
Just open a boot entry, and edit its kernel parameters as highlighted in the screenshot below:
edited May 19 '18 at 8:33
David Foerster
27.8k1364110
27.8k1364110
answered Dec 11 '12 at 1:59
jasxunjasxun
35625
35625
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%2f19486%2fhow-do-i-add-a-kernel-boot-parameter%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