New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 801889 link

Starred by 7 users

Issue metadata

Status: Fixed
Owner:
Closed: Mar 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Mac
Pri: 2
Type: Bug-Regression



Sign in to add a comment

Chromium does not open any webpage also not settings page only with cli option "no-sandbox"

Reported by sco_...@gmx.de, Jan 14 2018

Issue description

UserAgent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/63.0.3239.132 Safari/537.36

Steps to reproduce the problem:
Open browser

What is the expected behavior?
Open web page or settings page

What went wrong?
User agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/63.0.3239.132 Safari/537.36

The current release (Version 63.0.3239.132 (Developer Build) 64-bit) and the last three before this one stopped working for me with any website. So when I try to go to a webpage like www.google.com I see that the browser is doing a DNS request but after that nothing happens (spinning circle in tab view). After a while the "page is unresponsive" pop-up comes up and the complete window freezes. Also internal settings pages do not work anymore. Only by using the "--no-sandbox" option it works again. Already tried to remove the default profile and start fresh, deleting caches and deleting the application nothing works. Also tried incognito mode and loading without any extensions etc. 

It keeps saying "Waiting for www.google.com" and in the logfile the last entry is: 
[7808:45571:0114/150806.126667:VERBOSE1:network_delegate.cc(30)] NetworkDelegate::NotifyBeforeURLRequest: https://www.google.com

When the application crashed I have to force it with "Force Quit" so simply closing is not sufficient.

Version: Version 63.0.3239.132 (Developer Build) (64-bit)
Mac OS: Sierra Version 10.12.6 (16G1206)

Crashed report ID: 

How much crashed? Whole browser

Is it a problem with a plugin? No 

Did this work before? Yes Chromium_OSX_62.0.3202.89

Chrome version: 63.0.3239.132  Channel: dev
OS Version: OS X 10.12.6
Flash Version:
 

Comment 1 by meh...@chromium.org, Jan 15 2018

Can you please attach the Apple crash log here. Thanks.
Labels: Needs-Feedback

Comment 3 by sco_...@gmx.de, Jan 17 2018

Crash log
crash report.txt
37.5 KB View Download
Project Member

Comment 4 by sheriffbot@chromium.org, Jan 17 2018

Cc: spqc...@chromium.org
Labels: -Needs-Feedback
Thank you for providing more feedback. Adding requester "spqchan@chromium.org" to the cc list and removing "Needs-Feedback" label.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Labels: Needs-Bisect Needs-Triage-M63
Cc: sc00335...@techmahindra.com
Components: Internals>Sandbox
Labels: Triaged-ET TE-NeedsTriageFromHYD
Unable to reproduce this issue on chromium 63.0.3239.132 using Mac 10.12.6. Launched chromium without any flag and observed no crash, Launched chromium with "--no-sandbox" option and observed no crash. Able to navigate to websites amazon.com,facebook etc..

As issue is not reproducible from ET team. Could someone from Inhouse team take a look at attached crash log and triage this further.

Thanks!
Cc: kkaluri@chromium.org
Unable to reproduce the issue on Mac 10.12.6 with chromium 63.0.3239.0 
Launched chromium with "--no-sandbox" flag and didn't observe any crash, able to navigate to different websites.

Note: Chromium is downloaded from https://commondatastorage.googleapis.com/chromium-browser-snapshots/index.html

Comment 8 by sco_...@gmx.de, Jan 23 2018

Can I provide somehow more information on my bug? Because my browser is still not showing any webpage without the "--no-sandbox" option

I downloaded my binary from: https://sourceforge.net/projects/osxportableapps/files/Chromium/

Comment 9 by rsesek@chromium.org, Jan 23 2018

Sorry, we don't support those sourceforge (or any) Chromium builds. If you launch Chromium from the command line, it may print an error message that can be used to debug further.

Comment 10 by sco_...@gmx.de, Jan 30 2018

Is there a (trustworthy) source for chromium builds? I couldn't find one. But I took in on me and compiled a version myself, after patiently waiting 7 hrs I now have a version 66.0.3335.0 (Developer Build) (64-bit) running. But same issue again, without the "--no-sandbox" option on the cli I do not even get to the about page. I have the following error messages on my console: 

[56945:45059:0130/090202.600184:ERROR:child_process_launcher_helper_mac.cc(154)] pipe for sending sandbox profile is an invalid FD
[56945:45059:0130/090202.602547:ERROR:child_process_launcher_helper_mac.cc(154)] pipe for sending sandbox profile is an invalid FD
[56945:46595:0130/090202.604242:ERROR:service_manager_context.cc(253)] Attempting to run unsupported native service: /Applications/Chromium.app/Contents/Versions/66.0.3335.0/Chromium Framework.framework/Versions/A/content_renderer.service
[56945:45059:0130/090203.176334:ERROR:child_process_launcher_helper_mac.cc(154)] pipe for sending sandbox profile is an invalid FD
[56945:45059:0130/090203.277043:ERROR:child_process_launcher_helper_mac.cc(154)] pipe for sending sandbox profile is an invalid FD

Owner: kerrnel@chromium.org
Status: Assigned (was: Unconfirmed)
Over to kerrnel to see if he knows common causes for this error message.
Labels: -Needs-Bisect -TE-NeedsTriageFromHYD
As this issue is not reproducible from hyd team ,removing TE-NeedsTriageFromHYD & Needs-Bisect labels for now.

Thanks..!
There's a lot happening in this bug, so I need to collect more information to unwind this,

"The current release (Version 63.0.3239.132 (Developer Build) 64-bit) and the last three before this one stopped working for me" --> are you saying that Chrome hasn't been able to load any web pages since release 59?

Also starting in M-64, Chromium is using a new sandbox, so that error about the invalid FD is strange, but definitely not related to your problems with 63. 

Comment 14 by sco_...@gmx.de, Feb 3 2018

Sorry for not being specifc enough about "which" last three versions stopped working for me.
First Version which did not work for me anymore is: Chromium_OSX_63.0.3239.84 and all versions after this one.
Last known working version is: Chromium_OSX_62.0.3202.94

Owner: ----
Status: Available (was: Assigned)
The new sandbox didn't ship in 63 so this seems unrelated. I'm not sure what's going on here but passed on the log about invalid FDs, I wonder if your machine is running out of file descriptors.

I don't appear to be the right owner for this bug at this point.

Comment 16 by sco_...@gmx.de, Feb 12 2018

Anything I can do/provide?  
Cc: kerrnel@chromium.org
Can you provide a link to the exact build you're running, and then launch it from the command line using:

$ /path/to/Chromium.app/Contents/MacOS/Chromium --user-data-dir=/tmp/profile --enable-features=MacV2Sandbox

Then paste all the log messages here.

+kerrnel because I'm not convinced that you're not the right owner :)
 Issue 811198  has been merged into this issue.
Please also run with --disable-features=MacV2Sandbox so that we can compare the two.

$ /path/to/Chromium.app/Contents/MacOS/Chromium --user-data-dir=/tmp/profile --disable-features=MacV2Sandbox
I am having a similar issue (811198), which has been merged with this one, so I'm here to add my voice.

After updating to v63.x, no web pages would open at all. I didn't even get the "loading" graphic in the tab — just tabs completely devoid of *any* content -- just a plain white space with nothing on it at all, no matter how long I waited.

I reverted to v62 (from a Time Machine backup). I should have reported the issue here, but I was swamped at the time, and working under a deadline. So instead, I've been ignoring the notification from FreeSMUG Updater for a few weeks, thinking I'd just try again after a while to see if the problem had been fixed.

Yesterday, I updated to v64.x, and not only had the same problem as before, but this time there are two new data points: an "unhappy" favicon in each browser tab (although each tab was still otherwise completely empty), and the fact that I received crash notifications (within Chromium) from every extension (including FreeSMUG). When I clear those notifications, they just come right back up.

Also, unlike the original report above, I have not had Chromium crash during all of this. It just won't, you know, *work*.

I have not tried rebooting in Safe mode or the "--no-sandbox" method mentioned above (willing to test it, but I'll need some instruction). But I have tried creating a fresh Chromium user with no history or extensions, and still had the problem, and I did try every user in my People menu, and they all had the problem. And for the record, when launching any user, all the previous tabs were still shown, they just were all devoid of content.

I have once again reverted to v62, but I'm willing to reinstall and test, and/or screenshare with anyone who wants to see the problem in action.

FYI, I'm running Mac 10.11.6 on a Mid-2009 MacBook Pro 13".
Thanks for the additional information. Right now the most helpful thing would be running with the following flags (separately since the flags are all opposites):
--no-sandbox
--enable-features=MacV2Sandbox
--disable-features=MacV2Sandbox
Happy to give that a go. I have little experience in Terminal, so let me make sure I'm reading the instructions correctly. When you say...

$ /path/to/Chromium.app/Contents/MacOS/Chromium --user-data-dir=/tmp/profile --disable-features=MacV2Sandbox

...the "/path/to/" means, for example, "/Macintosh HD/Applications/"

...and is "user-data-dir=/tmp/profile" literally that (i.e., using this will create a temporary profile), or do I need to provide a path to the profile I wish to launch? If so, please provide an example I can follow. (I'm very much a tech guy, but command-line stuff is where my know-how drops off considerably.)

You're correct about all those points, you just want to use a temporary profile.

So my command line flag is:

$ /Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome --user-data-dir=/tmp/foo343 --disable-features=MacV2Sandbox
Roger that. And how do I get the logs you're looking for as a result? Will they just occur in the Terminal by running the app from the command line? Or do I need to hunt for them somewhere?
If you run the app on the command line, it will print log messages into terminal, yes. You'll see the output.
Gave this a go...

$ /Name of My HD/Applications/Chromium.app/Contents/MacOS/Chromium --user-data-dir=/tmp/profile --no-sandbox

...(with the actual two-word name of my HD where I said "Name of My HD") but all that happened was a new line in the terminal with just a caret (>). Literally nothing else happened. Probably user error. Like I said, command-line stuff is where my knowhow drops off a cliff.
Hard to say without the specific command line. Do you have Google Chrome or Chromium installed? Did you put \ before all the spaces in your HD name?

"/Name of HD" needs to be "/Name\ of\ HD" or the command line thinks it's separate commands.
OK, found my way there. I needed to leave off the "$ /Name\ of \HD" and just start with ...

/Applications/Chromium.app/Contents/MacOS/Chromium --user-data-dir=/tmp/profile --WHATEVER

Results below.

Upshot:
Could browse normally when launched with --no-sandbox and --disable-features=MacV2Sandbox.
Nothing would load content at all (including launch page or Settings) when launched with --enable-features=MacV2Sandbox. (Screenshot attached.)

I have 64.0.3282.140 still installed, so holler if you want me to try something new.


/Applications/Chromium.app/Contents/MacOS/Chromium --user-data-dir=/tmp/profile --no-sandbox

[30994:43779:0212/170601.064143:ERROR:browser_gpu_channel_host_factory.cc(121)] Failed to launch GPU process.
[30994:43779:0212/170601.939527:ERROR:browser_gpu_channel_host_factory.cc(121)] Failed to launch GPU process.
[30994:1295:0212/170602.105746:ERROR:gpu_process_transport_factory.cc(1009)] Lost UI shared context.



/Applications/Chromium.app/Contents/MacOS/Chromium --user-data-dir=/tmp/profile --enable-features=MacV2Sandbox

[31207:44035:0212/170852.962691:ERROR:browser_gpu_channel_host_factory.cc(121)] Failed to launch GPU process.
[31207:42755:0212/170853.261172:ERROR:child_process_launcher_helper_mac.cc(73)] pipe for sending sandbox profile is an invalid FD
[31207:42755:0212/170853.550002:ERROR:child_process_launcher_helper_mac.cc(73)] pipe for sending sandbox profile is an invalid FD
[31207:44035:0212/170853.553128:ERROR:service_manager_context.cc(219)] Attempting to run unsupported native service: /Applications/Chromium.app/Contents/Versions/64.0.3282.140/Chromium Framework.framework/Versions/A/content_renderer.service
[31207:42755:0212/170912.471971:ERROR:child_process_launcher_helper_mac.cc(73)] pipe for sending sandbox profile is an invalid FD
[31207:44035:0212/170912.472785:ERROR:service_manager_context.cc(219)] Attempting to run unsupported native service: /Applications/Chromium.app/Contents/Versions/64.0.3282.140/Chromium Framework.framework/Versions/A/content_renderer.service
[31207:42755:0212/170912.518613:ERROR:child_process_launcher_helper_mac.cc(73)] pipe for sending sandbox profile is an invalid FD
[31207:44035:0212/170912.520469:ERROR:service_manager_context.cc(219)] Attempting to run unsupported native service: /Applications/Chromium.app/Contents/Versions/64.0.3282.140/Chromium Framework.framework/Versions/A/content_renderer.service
[31207:44035:0212/170912.522349:ERROR:browser_gpu_channel_host_factory.cc(121)] Failed to launch GPU process.
[31207:42755:0212/170913.214439:ERROR:child_process_launcher_helper_mac.cc(73)] pipe for sending sandbox profile is an invalid FD
[31207:42755:0212/170929.074942:ERROR:child_process_launcher_helper_mac.cc(73)] pipe for sending sandbox profile is an invalid FD
[31207:44035:0212/170929.079355:ERROR:service_manager_context.cc(219)] Attempting to run unsupported native service: /Applications/Chromium.app/Contents/Versions/64.0.3282.140/Chromium Framework.framework/Versions/A/content_renderer.service
[31207:44035:0212/170929.110983:ERROR:browser_gpu_channel_host_factory.cc(121)] Failed to launch GPU process.
[31207:42755:0212/170929.122042:ERROR:child_process_launcher_helper_mac.cc(73)] pipe for sending sandbox profile is an invalid FD
[31207:44035:0212/170929.129071:ERROR:browser_gpu_channel_host_factory.cc(121)] Failed to launch GPU process.
[31207:44035:0212/170929.130319:ERROR:service_manager_context.cc(219)] Attempting to run unsupported native service: /Applications/Chromium.app/Contents/Versions/64.0.3282.140/Chromium Framework.framework/Versions/A/content_renderer.service




/Applications/Chromium.app/Contents/MacOS/Chromium --user-data-dir=/tmp/profile --disable-features=MacV2Sandbox

[31216:43779:0212/171019.486151:ERROR:browser_gpu_channel_host_factory.cc(121)] Failed to launch GPU process.
[31216:43779:0212/171020.113333:ERROR:browser_gpu_channel_host_factory.cc(121)] Failed to launch GPU process.
[31216:1295:0212/171020.197986:ERROR:gpu_process_transport_factory.cc(1009)] Lost UI shared context.
Oops. Reloaded because CAPTCHA failed, and lost the attachment in the process. Here it is.
Chromium v64 no content.png
42.0 KB View Download
Owner: kerrnel@chromium.org
Status: Assigned (was: Available)
Thanks a bunch for that. The first step here is that I need to add more logging to understand what's happening.
Project Member

Comment 31 by bugdroid1@chromium.org, Feb 13 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/78e7405af0e16c10500bc5b923e938ad9f52e735

commit 78e7405af0e16c10500bc5b923e938ad9f52e735
Author: Greg Kerr <kerrnel@chromium.org>
Date: Tue Feb 13 21:56:37 2018

macOS V2 Sandbox: Add logging to failures in profile communication.

This adds additional logging to the SeatbeltExecClient so that uses
experiencing launch failures in the sandbox initialization path can
report exactly what failed.

Bug:  801889 
TBR: creis@chromium.org
Change-Id: I425bedc92d47a27f90b4d80541d2cbf68e8f6a21
Reviewed-on: https://chromium-review.googlesource.com/916946
Commit-Queue: Greg Kerr <kerrnel@chromium.org>
Reviewed-by: Robert Sesek <rsesek@chromium.org>
Cr-Commit-Position: refs/heads/master@{#536495}
[modify] https://crrev.com/78e7405af0e16c10500bc5b923e938ad9f52e735/content/browser/child_process_launcher_helper_mac.cc
[modify] https://crrev.com/78e7405af0e16c10500bc5b923e938ad9f52e735/sandbox/mac/seatbelt_exec.cc

Thanks again for looking into this. I added more logging so that we can understand exactly what's failing. I'm not sure how you're acquiring your Chromium builds, but are you able to try again with a build that includes the change just committed?

You could also try this with the Google Chrome Canary build if you wish, this CL should be in tomorrow's Canary.
I get my builds via the FreeSMUG Updater extension, which checks for new builds at launch. The URL it directed me to for the latest was https://sourceforge.net/projects/osxportableapps/files/Chromium/Chromium_OSX_64.0.3282.140.dmg/download

If you point me to a place to download the build you created with the additional logging, I'll test it for you. I assume you'd want me to launch via Terminal again to get those logs, yes?
I think a popular location is https://download-chromium.appspot.com/. The "Build Revision" will need to be >= 536495 (which it currently is not – that will probably be ready in an hour or two).
Correct. Tomorrow if you fetch Google Chrome Canary from here (https://www.google.com/chrome/browser/canary.html) it should have the change and can be launched from the command line.
I went to https://download-chromium.appspot.com/ after several hours, but it loos like I missed the 536495 build. It's currently offering up 536620. Will that have the additional logging too?
Any build after 536495 is fine, so 536620 and higher will have the additional debug logging.
OK, I installed from https://download-chromium.appspot.com/, and here's what I got running the same command-line launches as before:

Again, could browse normally when launched with --no-sandbox and --disable-features=MacV2Sandbox.
Nothing would load content at all (including launch page or Settings) when launched with --enable-features=MacV2Sandbox.


/Applications/Chromium.app/Contents/MacOS/Chromium --user-data-dir=/tmp/profile --no-sandbox

[38144:1295:0214/140231.832710:ERROR:gpu_process_transport_factory.cc(1017)] Lost UI shared context.
[38149:775:0214/140317.155757:ERROR:context_group.cc(137)] ContextResult::kFatalFailure: WebGL1 blacklisted
[38149:775:0214/140317.197731:ERROR:context_group.cc(137)] ContextResult::kFatalFailure: WebGL1 blacklisted



/Applications/Chromium.app/Contents/MacOS/Chromium --user-data-dir=/tmp/profile --enable-features=MacV2Sandbox

Feb 14 14:04:26  Chromium[38167] <Error>: SeatbeltExecClient: short writev(). written: 512, str->size(): 5927
Feb 14 14:04:26  Chromium[38167] <Error>: SeatbeltExecClient: Writing the serialized profile failed.
[38167:40451:0214/140426.390996:ERROR:child_process_launcher_helper_mac.cc(160)] Sending the seatbelt profile failed.
Feb 14 14:04:26  Chromium[38167] <Error>: SeatbeltExecClient: short writev(). written: 512, str->size(): 5927
Feb 14 14:04:26  Chromium[38167] <Error>: SeatbeltExecClient: Writing the serialized profile failed.
[38167:40451:0214/140426.398453:ERROR:child_process_launcher_helper_mac.cc(160)] Sending the seatbelt profile failed.
Feb 14 14:04:26  Chromium[38167] <Error>: SeatbeltExecClient: short writev(). written: 512, str->size(): 5927
Feb 14 14:04:26  Chromium[38167] <Error>: SeatbeltExecClient: Writing the serialized profile failed.
[38167:40451:0214/140426.404840:ERROR:child_process_launcher_helper_mac.cc(160)] Sending the seatbelt profile failed.
[38167:41219:0214/140426.411826:ERROR:browser_gpu_channel_host_factory.cc(120)] Failed to launch GPU process.
Feb 14 14:04:26  Chromium[38167] <Error>: SeatbeltExecClient: short writev(). written: 512, str->size(): 6298
Feb 14 14:04:26  Chromium[38167] <Error>: SeatbeltExecClient: Writing the serialized profile failed.
[38167:40451:0214/140426.642555:ERROR:child_process_launcher_helper_mac.cc(160)] Sending the seatbelt profile failed.
[38167:41219:0214/140426.643298:ERROR:service_manager_context.cc(254)] Attempting to run unsupported native service: /Applications/Chromium.app/Contents/Versions/66.0.3348.0/Chromium Framework.framework/Versions/A/content_renderer.service
[38167:1295:0214/140427.149834:ERROR:gpu_process_transport_factory.cc(1017)] Lost UI shared context.
Feb 14 14:04:27  Chromium[38167] <Error>: SeatbeltExecClient: short writev(). written: 512, str->size(): 6298
Feb 14 14:04:27  Chromium[38167] <Error>: SeatbeltExecClient: Writing the serialized profile failed.
[38167:40451:0214/140427.213274:ERROR:child_process_launcher_helper_mac.cc(160)] Sending the seatbelt profile failed.



/Applications/Chromium.app/Contents/MacOS/Chromium --user-data-dir=/tmp/profile --disable-features=MacV2Sandbox

[38176:1295:0214/140515.472777:ERROR:gpu_process_transport_factory.cc(1017)] Lost UI shared context.
Feb 14 14:05:44  Chromium Helper[38189] <Warning>: CGSConnectionByID: 0 is not a valid connection ID.
Feb 14 14:05:44  Chromium Helper[38189] <Warning>: Invalid Connection ID 0


Thanks for the information. That answers that. You can fix this for now by going to chrome://flags/#mac-v2-sandbox and setting the experiment to disabled.
Sounds good...except that I can't get *any* tab to load anything in v64.x, so I literally can't get to chrome://flags/#mac-v2-sandbox.

Should I do this in v62.x then install v64.x?

Also, I'm guessing I need to do this for each Chromium user in the People menu. Is that right, or is it a universal setting?

That's right. Sorry for the confusion and the inconvenience. Also thanks so much for going the extra mile to help us debug this, we'd have no idea how to fix this without your report and help!

Launch from the command line with --disable-features=MacV2Sandbox but without that --user-data-dir flag. This will change the setting in your actual profile and you'll be good to go on all future launches.
Always happy to help bugfix software that I use daily. :) Helping you helps me!

I assume there will come a time when I should turn MacV2Sandbox back on? Should I watch this thread for an update?
Yes. And eventually, once all the bugs are ironed out through our beta testing, the V2 sandbox will be the only sandbox, and that flag to disable it won't work anymore. So you could also do nothing and eventually be on the new sandbox.

By the  way, I'm wondering why your particular machine saw this failure. Do you use any custom sysctl's? If you don't know what a sysctl is the answer is no. :-)
Then the answer is no. :) But feel free to ask any more questions that occur to you.

Comment 45 by sco_...@gmx.de, Feb 15 2018

I can confirm, this solves the issue also for me! Thanks! As far as I know I do not have any special sysctl's set. 
Project Member

Comment 46 by bugdroid1@chromium.org, Feb 16 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/7ea6cf78e3bced2f48c49394493832520cdc97f0

commit 7ea6cf78e3bced2f48c49394493832520cdc97f0
Author: Greg Kerr <kerrnel@chromium.org>
Date: Fri Feb 16 18:39:23 2018

macOS V2 Sandbox: Send serialized seatbelt profile in a loop.

In some cases, and on user's machines per bug reports, writev() performs
a short write. The child process receives an invalid profile and tabs
fail to launch. This switches to using a sequence of write() calls to
send the buffer length, and then send the buffer in a loop.

Bug:  801889 
Change-Id: Ib1f4c57c61d3ce68b875b347de480f514100d3c2
Reviewed-on: https://chromium-review.googlesource.com/920765
Reviewed-by: Robert Sesek <rsesek@chromium.org>
Commit-Queue: Greg Kerr <kerrnel@chromium.org>
Cr-Commit-Position: refs/heads/master@{#537360}
[modify] https://crrev.com/7ea6cf78e3bced2f48c49394493832520cdc97f0/sandbox/mac/seatbelt_exec.cc
[modify] https://crrev.com/7ea6cf78e3bced2f48c49394493832520cdc97f0/sandbox/mac/seatbelt_exec.h

If either of the reporters don't mind testing the new CL, that would be a great help, since I can't reproduce this. Grab a chromium build after revision 537360, and then run:

/Applications/Chromium.app/Contents/MacOS/Chromium --user-data-dir=/tmp/profile345 --enable-features=MacV2Sandbox


It should work with the new CL.
Status: Fixed (was: Assigned)
Downloaded Build Revision: 537413 and ran "--user-data-dir=/tmp/profile345 --enable-features=MacV2Sandbox" as requested. No dice:

/Applications/Chromium.app/Contents/MacOS/Chromium --user-data-dir=/tmp/profile345 --enable-features=MacV2Sandbox

Feb 16 15:12:26  Chromium[47580] <Error>: SeatbeltExecClient: write failed: Resource temporarily unavailable
Feb 16 15:12:26  Chromium[47580] <Error>: SeatbeltExecClient: Writing the serialized profile failed.
[47580:41219:0216/151226.011337:ERROR:child_process_launcher_helper_mac.cc(160)] Sending the seatbelt profile failed.
Feb 16 15:12:26  Chromium[47580] <Error>: SeatbeltExecClient: write failed: Resource temporarily unavailable
Feb 16 15:12:26  Chromium[47580] <Error>: SeatbeltExecClient: Writing the serialized profile failed.
[47580:41219:0216/151226.022369:ERROR:child_process_launcher_helper_mac.cc(160)] Sending the seatbelt profile failed.
Feb 16 15:12:26  Chromium[47580] <Error>: SeatbeltExecClient: write failed: Resource temporarily unavailable
Feb 16 15:12:26  Chromium[47580] <Error>: SeatbeltExecClient: Writing the serialized profile failed.
[47580:41219:0216/151226.035135:ERROR:child_process_launcher_helper_mac.cc(160)] Sending the seatbelt profile failed.
[47580:29187:0216/151226.113252:ERROR:browser_gpu_channel_host_factory.cc(120)] Failed to launch GPU process.
Feb 16 15:12:26  Chromium[47580] <Error>: SeatbeltExecClient: write failed: Resource temporarily unavailable
Feb 16 15:12:26  Chromium[47580] <Error>: SeatbeltExecClient: Writing the serialized profile failed.
[47580:41219:0216/151226.239657:ERROR:child_process_launcher_helper_mac.cc(160)] Sending the seatbelt profile failed.
[47580:1295:0216/151226.774786:ERROR:gpu_process_transport_factory.cc(1017)] Lost UI shared context.
Feb 16 15:12:26  Chromium[47580] <Error>: SeatbeltExecClient: write failed: Resource temporarily unavailable
Feb 16 15:12:26  Chromium[47580] <Error>: SeatbeltExecClient: Writing the serialized profile failed.
[47580:41219:0216/151226.804161:ERROR:child_process_launcher_helper_mac.cc(160)] Sending the seatbelt profile failed.
[47580:29187:0216/151226.811415:ERROR:service_manager_context.cc(257)] Attempting to run unsupported native service: /Applications/Chromium.app/Contents/Versions/66.0.3351.0/Chromium Framework.framework/Versions/A/content_renderer.service
Feb 16 15:12:26  Chromium[47580] <Error>: SeatbeltExecClient: write failed: Resource temporarily unavailable
Feb 16 15:12:27  Chromium[47580] <Error>: SeatbeltExecClient: Writing the serialized profile failed.
[47580:41219:0216/151227.000547:ERROR:child_process_launcher_helper_mac.cc(160)] Sending the seatbelt profile failed.
Feb 16 15:12:27  Chromium[47580] <Error>: SeatbeltExecClient: write failed: Resource temporarily unavailable
Feb 16 15:12:27  Chromium[47580] <Error>: SeatbeltExecClient: Writing the serialized profile failed.
[47580:41219:0216/151227.055815:ERROR:child_process_launcher_helper_mac.cc(160)] Sending the seatbelt profile failed.
[47580:29187:0216/151227.063578:ERROR:service_manager_context.cc(257)] Attempting to run unsupported native service: /Applications/Chromium.app/Contents/Versions/66.0.3351.0/Chromium Framework.framework/Versions/A/content_renderer.service
Thanks. Sorry about that, looks like the loop needs to handle EAGAIN as well. I'll fix that.
FYI, looks like this problem has gotten "into the wild." This afternoon Google Chrome failed to load every tab and displayed all the same symptoms I described in my first post above. I restored a previous build of Chrome from Time Machine and disabled chrome://flags/#mac-v2-sandbox.
Thanks, what version of Google Chrome was showing the problem?
Status: Started (was: Fixed)
Google Chrome 64.0.3282.167
Unable to reproduce this issue on the reported Chromium #63.0.3239.132 using Mac 10.13.3 from TE's end as commented in C#6 & 7. Request dev to verify the fix landed.

Thanks!
Project Member

Comment 56 by bugdroid1@chromium.org, Feb 22 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/fb63be6d346dbbbe47e3edf3a7e8e6b6b7f286d7

commit fb63be6d346dbbbe47e3edf3a7e8e6b6b7f286d7
Author: Greg Kerr <kerrnel@chromium.org>
Date: Thu Feb 22 17:42:03 2018

macOS V2 Sandbox: Continue sending profile if EAGAIN occurs.

If a write or a read files and the errno is EAGAIN, it needs to continue
trying to send the sandbox profile.

Bug:  801889 
Change-Id: I1a6c91fc348a20804b06d0bb64fbcd17cccea20f
Reviewed-on: https://chromium-review.googlesource.com/924246
Commit-Queue: Greg Kerr <kerrnel@chromium.org>
Reviewed-by: Mark Mentovai <mark@chromium.org>
Reviewed-by: Robert Sesek <rsesek@chromium.org>
Cr-Commit-Position: refs/heads/master@{#538474}
[modify] https://crrev.com/fb63be6d346dbbbe47e3edf3a7e8e6b6b7f286d7/sandbox/mac/seatbelt_exec.cc

Status: Fixed (was: Started)
This should now work in a build after 538474. The IPC handles short writes and EAGAIN correctly.
Cc: awhalley@chromium.org
Labels: -Needs-Triage-M63 Merge-Request-65
Requesting Merge to 65. We should not proceed with broader V2 sandbox rollout without this CL since we can't know how many users could get hit by this bug. 
Note: the CL is in last nights canary which I tested.
Project Member

Comment 60 by sheriffbot@chromium.org, Feb 23 2018

Labels: -Merge-Request-65 Merge-Review-65 Hotlist-Merge-Review
This bug requires manual review: We are only 10 days from stable.
Please contact the milestone owner if you have questions.
Owners: cmasso@(Android), cmasso@(iOS), bhthompson@(ChromeOS), govind@(Desktop)

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
How safe is the change to merge to M65 as we're very close to M65 stable promotion? And this has been exits since M63, can't this wait until M66?
The change is safe to merge. I think the regression being marked as M63 is incorrect, the feature that caused this wasn't rolled out until M-64. This is safe to merge because if the low risk Cl did cause any problems, we could disable the entire feature via Finch flag. But without this merge we'll have to abort the current rollout to stable and pause everything for several months, which we should not do over a low risk merge.
Labels: -Merge-Review-65 Merge-Approved-65
Approving merge to M65 branch 3325 based on comment #62 and per offline chat with awhalley@.
Project Member

Comment 64 by bugdroid1@chromium.org, Feb 23 2018

Labels: -merge-approved-65 merge-merged-3325
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/5a132477364665a02816a87f1ca68870cb20e545

commit 5a132477364665a02816a87f1ca68870cb20e545
Author: Greg Kerr <kerrnel@chromium.org>
Date: Fri Feb 23 23:09:17 2018

[merge m-65]: macOS V2 Sandbox: Send profile to child process robustly.

This is CL squashes three cherry-picks into one CL for the purpose of
merging to m-65. The CLs make IPC of the seatbelt profile from the
browser to the child process robust by adding logging and handling short
writes or temporarily busy file descriptors.

Original CLs:
78e7405af0e16c10500bc5b923e938ad9f52e735
macOS V2 Sandbox: Add logging to failures in profile communication.
Change-Id: I425bedc92d47a27f90b4d80541d2cbf68e8f6a21
Reviewed-on: https://chromium-review.googlesource.com/916946
Cr-Commit-Position: refs/heads/master@{#536495}

7ea6cf78e3bced2f48c49394493832520cdc97f0
macOS V2 Sandbox: Send serialized seatbelt profile in a loop.
Change-Id: Ib1f4c57c61d3ce68b875b347de480f514100d3c2
Reviewed-on: https://chromium-review.googlesource.com/920765
Cr-Commit-Position: refs/heads/master@{#537360}

fb63be6d346dbbbe47e3edf3a7e8e6b6b7f286d7
macOS V2 Sandbox: Continue sending profile if EAGAIN occurs.
Change-Id: I1a6c91fc348a20804b06d0bb64fbcd17cccea20f
Reviewed-on: https://chromium-review.googlesource.com/924246
Cr-Commit-Position: refs/heads/master@{#538474}

Bug:  801889 
Change-Id: I421f83dfa58ad2990e4f6fe304f9713cfa9d6b60
Reviewed-on: https://chromium-review.googlesource.com/935664
Reviewed-by: Robert Sesek <rsesek@chromium.org>
Reviewed-by: Mark Mentovai <mark@chromium.org>
Cr-Commit-Position: refs/branch-heads/3325@{#579}
Cr-Branched-From: bc084a8b5afa3744a74927344e304c02ae54189f-refs/heads/master@{#530369}
[modify] https://crrev.com/5a132477364665a02816a87f1ca68870cb20e545/content/browser/child_process_launcher_helper_mac.cc
[modify] https://crrev.com/5a132477364665a02816a87f1ca68870cb20e545/sandbox/mac/seatbelt_exec.cc
[modify] https://crrev.com/5a132477364665a02816a87f1ca68870cb20e545/sandbox/mac/seatbelt_exec.h

An additional fix is needed for this, so we've disabled the macOS V2 Sandbox experiment on M-64 and M-65, and a fix is in review for top of tree. This will be fixed in M-66 and the V2 sandbox will go to stable in 66 now.
I finally reproduced by artificially creating the conditions we believe cause this hang. If the browser sends a message greater than BUF_PIPE length (meaning the kernel can't buffer it), the tabs all hang in an infinite loop as it keeps receiving EAGAIN. We think the bug happens to some users who are either under memory pressure or, due to really long strings in the sandbox profile, have to transmit a message greater than BUF_PIPE.

The new CL fixes this case: it now launches the child and then sends the whole profile as soon as the child is ready to receive it. 
Status: Started (was: Fixed)
Issue 816824 has been merged into this issue.
Project Member

Comment 69 by sheriffbot@chromium.org, Feb 28 2018

Labels: FoundIn-M-66 Fracas
Users experienced this crash on the following builds:

Mac Dev 66.0.3355.0 -  1.29 CPM, 1 reports, 1 clients (signature [Shutdown hang] sandbox::SeatbeltExecClient::WriteString)

If this update was incorrect, please add "Fracas-Wrong" label to prevent future updates.

- Go/Fracas
Project Member

Comment 70 by bugdroid1@chromium.org, Mar 1 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/9eb9a290742a97d0eb712d9c25774cc307709e46

commit 9eb9a290742a97d0eb712d9c25774cc307709e46
Author: Greg Kerr <kerrnel@chromium.org>
Date: Thu Mar 01 17:11:24 2018

macOS V2 Sandbox: Correct ordering of seatbelt IPC.

This CL establishes the correct ordering of the IPC which transmits the
seatbelt profile to the child process. It must first map the FD into the
child process, while launching the child process, and only send the
profile once the child process is launched.

Bug: 816824, 801889 
Change-Id: I453e307cc8f9a7416011ecc4eb101e702b11bca0
Reviewed-on: https://chromium-review.googlesource.com/939986
Reviewed-by: Robert Sesek <rsesek@chromium.org>
Reviewed-by: Mark Mentovai <mark@chromium.org>
Reviewed-by: Charlie Reis <creis@chromium.org>
Commit-Queue: Greg Kerr <kerrnel@chromium.org>
Cr-Commit-Position: refs/heads/master@{#540194}
[modify] https://crrev.com/9eb9a290742a97d0eb712d9c25774cc307709e46/content/browser/child_process_launcher_helper.h
[modify] https://crrev.com/9eb9a290742a97d0eb712d9c25774cc307709e46/content/browser/child_process_launcher_helper_mac.cc
[modify] https://crrev.com/9eb9a290742a97d0eb712d9c25774cc307709e46/sandbox/mac/seatbelt_exec.cc
[modify] https://crrev.com/9eb9a290742a97d0eb712d9c25774cc307709e46/sandbox/mac/seatbelt_exec.h

Labels: Needs-Feedback
Unable to reproduce this issue from TE end as per comments# 6,7 and 12. Hence unable to verify this issue.

@kerrnel: Please help in verifying the fix as it is not reproducible from TE end.

Thanks!
Status: Fixed (was: Started)

Sign in to add a comment