Cannot write to efivars

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP








up vote
0
down vote

favorite












I have booted from an Ubuntu 17.10.1 live DVD on a 2011 MacBook Pro (in EFI mode) and I'm trying to issue the following command to disable the discrete GPU:



printf "x01x00x00x00" > /sys/firmware/efi/efivars/gpu-power-prefs-fa4ce28d-b62f-4c99-9cc3-6815686e30f9



And I am getting this error no matter what I do:



bash: printf: write error: Invalid argument



I know this question has been asked and answered before, but I have already verified that the efivars filesystem is mounted rw and I have removed the immutability flag with chattr -i.



I can touch the file to create it, and I can delete it with rm, but any attempt to actually write data to the file at all results in a write error, whether I use echo, printf, or try to cp or mv the file from another writeable directory. Nothing seems to work.



I have also tried this in Debian and that didn't work either.



Those that are familiar with the MacBook Pro GPU bug might suggest that I boot into single user mode and issue an nvram command from there, but the laptop does not have an operating system installed to boot into (and I can't install macOS because of the GPU).



Is there no way to write to efivars anymore?










share|improve this question





















  • Did you try booting using cmd-option-r and booting to the MacOS / internet recovery option? From there, open a terminal (it's in one of the pull downs on the first page) and you can use Apple's "nvram" command to write to the NVRAM? I haven't used this for GPU issues but did while trying to disabled the Apple "bong" on bootup after a bare metal Ubuntu install to a macbook pro7,1.
    – randy
    May 10 at 19:09














up vote
0
down vote

favorite












I have booted from an Ubuntu 17.10.1 live DVD on a 2011 MacBook Pro (in EFI mode) and I'm trying to issue the following command to disable the discrete GPU:



printf "x01x00x00x00" > /sys/firmware/efi/efivars/gpu-power-prefs-fa4ce28d-b62f-4c99-9cc3-6815686e30f9



And I am getting this error no matter what I do:



bash: printf: write error: Invalid argument



I know this question has been asked and answered before, but I have already verified that the efivars filesystem is mounted rw and I have removed the immutability flag with chattr -i.



I can touch the file to create it, and I can delete it with rm, but any attempt to actually write data to the file at all results in a write error, whether I use echo, printf, or try to cp or mv the file from another writeable directory. Nothing seems to work.



I have also tried this in Debian and that didn't work either.



Those that are familiar with the MacBook Pro GPU bug might suggest that I boot into single user mode and issue an nvram command from there, but the laptop does not have an operating system installed to boot into (and I can't install macOS because of the GPU).



Is there no way to write to efivars anymore?










share|improve this question





















  • Did you try booting using cmd-option-r and booting to the MacOS / internet recovery option? From there, open a terminal (it's in one of the pull downs on the first page) and you can use Apple's "nvram" command to write to the NVRAM? I haven't used this for GPU issues but did while trying to disabled the Apple "bong" on bootup after a bare metal Ubuntu install to a macbook pro7,1.
    – randy
    May 10 at 19:09












up vote
0
down vote

favorite









up vote
0
down vote

favorite











I have booted from an Ubuntu 17.10.1 live DVD on a 2011 MacBook Pro (in EFI mode) and I'm trying to issue the following command to disable the discrete GPU:



printf "x01x00x00x00" > /sys/firmware/efi/efivars/gpu-power-prefs-fa4ce28d-b62f-4c99-9cc3-6815686e30f9



And I am getting this error no matter what I do:



bash: printf: write error: Invalid argument



I know this question has been asked and answered before, but I have already verified that the efivars filesystem is mounted rw and I have removed the immutability flag with chattr -i.



I can touch the file to create it, and I can delete it with rm, but any attempt to actually write data to the file at all results in a write error, whether I use echo, printf, or try to cp or mv the file from another writeable directory. Nothing seems to work.



I have also tried this in Debian and that didn't work either.



Those that are familiar with the MacBook Pro GPU bug might suggest that I boot into single user mode and issue an nvram command from there, but the laptop does not have an operating system installed to boot into (and I can't install macOS because of the GPU).



Is there no way to write to efivars anymore?










share|improve this question













I have booted from an Ubuntu 17.10.1 live DVD on a 2011 MacBook Pro (in EFI mode) and I'm trying to issue the following command to disable the discrete GPU:



printf "x01x00x00x00" > /sys/firmware/efi/efivars/gpu-power-prefs-fa4ce28d-b62f-4c99-9cc3-6815686e30f9



And I am getting this error no matter what I do:



bash: printf: write error: Invalid argument



I know this question has been asked and answered before, but I have already verified that the efivars filesystem is mounted rw and I have removed the immutability flag with chattr -i.



I can touch the file to create it, and I can delete it with rm, but any attempt to actually write data to the file at all results in a write error, whether I use echo, printf, or try to cp or mv the file from another writeable directory. Nothing seems to work.



I have also tried this in Debian and that didn't work either.



Those that are familiar with the MacBook Pro GPU bug might suggest that I boot into single user mode and issue an nvram command from there, but the laptop does not have an operating system installed to boot into (and I can't install macOS because of the GPU).



Is there no way to write to efivars anymore?







command-line kernel permissions uefi






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked Feb 9 at 16:57









Wes Sayeed

1011




1011











  • Did you try booting using cmd-option-r and booting to the MacOS / internet recovery option? From there, open a terminal (it's in one of the pull downs on the first page) and you can use Apple's "nvram" command to write to the NVRAM? I haven't used this for GPU issues but did while trying to disabled the Apple "bong" on bootup after a bare metal Ubuntu install to a macbook pro7,1.
    – randy
    May 10 at 19:09
















  • Did you try booting using cmd-option-r and booting to the MacOS / internet recovery option? From there, open a terminal (it's in one of the pull downs on the first page) and you can use Apple's "nvram" command to write to the NVRAM? I haven't used this for GPU issues but did while trying to disabled the Apple "bong" on bootup after a bare metal Ubuntu install to a macbook pro7,1.
    – randy
    May 10 at 19:09















Did you try booting using cmd-option-r and booting to the MacOS / internet recovery option? From there, open a terminal (it's in one of the pull downs on the first page) and you can use Apple's "nvram" command to write to the NVRAM? I haven't used this for GPU issues but did while trying to disabled the Apple "bong" on bootup after a bare metal Ubuntu install to a macbook pro7,1.
– randy
May 10 at 19:09




Did you try booting using cmd-option-r and booting to the MacOS / internet recovery option? From there, open a terminal (it's in one of the pull downs on the first page) and you can use Apple's "nvram" command to write to the NVRAM? I haven't used this for GPU issues but did while trying to disabled the Apple "bong" on bootup after a bare metal Ubuntu install to a macbook pro7,1.
– randy
May 10 at 19:09















active

oldest

votes











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',
convertImagesToLinks: true,
noModals: false,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);



);













 

draft saved


draft discarded


















StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1004619%2fcannot-write-to-efivars%23new-answer', 'question_page');

);

Post as a guest



































active

oldest

votes













active

oldest

votes









active

oldest

votes






active

oldest

votes















 

draft saved


draft discarded















































 


draft saved


draft discarded














StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1004619%2fcannot-write-to-efivars%23new-answer', 'question_page');

);

Post as a guest













































































Popular posts from this blog

pylint3 and pip3 broken

Missing snmpget and snmpwalk

How to enroll fingerprints to Ubuntu 17.10 with VFS491