Internal users are reporting /home/moblab/.moblab_id error |
||||||||
Issue descriptionThis is an intermittent fault - suspect a race condition of two callers of the get_moblab_id() function in client/common_lib/utils.py Harden this function to reduce the possibility of a race condition
,
May 19 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromiumos/third_party/autotest/+/fa0412a0c2817d29ea17dbd057f51bea85b35431 commit fa0412a0c2817d29ea17dbd057f51bea85b35431 Author: Keith Haddow <haddowk@chromium.org> Date: Fri May 19 20:57:42 2017 [moblab] Harden get_moblab_id against race conditions. Hard to reproduce report of errors when getting the moblab id - most likely caused by two version of gs_offloader starting at the same time trying to write to the moblab home directory. Improve error handling to count for this possiblity. TEST=manual tests BUG= chromium:723865 Change-Id: I0e890baf9a408134b8b2995228e2a256ab6db7be Reviewed-on: https://chromium-review.googlesource.com/508223 Commit-Ready: Keith Haddow <haddowk@chromium.org> Tested-by: Keith Haddow <haddowk@chromium.org> Reviewed-by: Keith Haddow <haddowk@chromium.org> Reviewed-by: Michael Tang <ntang@chromium.org> [modify] https://crrev.com/fa0412a0c2817d29ea17dbd057f51bea85b35431/client/common_lib/utils.py
,
May 19 2017
,
May 26 2017
Seeing error like this in R59
IOError: [Errno 13] Permission denied: '/home/moblab/.moblab_id'
Traceback (most recent call last):
File "/usr/local/autotest/frontend/afe/json_rpc/serviceHandler.py", line 120, in dispatchRequest
results['result'] = self.invokeServiceEndpoint(meth, args)
File "/usr/local/autotest/frontend/afe/json_rpc/serviceHandler.py", line 160, in invokeServiceEndpoint
return meth(*args)
File "/usr/local/autotest/frontend/afe/rpc_handler.py", line 270, in new_fn
return f(*args, **keyword_args)
File "/usr/local/autotest/frontend/afe/rpc_utils.py", line 1124, in verify
return func(*args, **kwargs)
File "/usr/local/autotest/frontend/afe/moblab_rpc_interface.py", line 439, in get_version_info
version_response['MOBLAB_ID'] = site_utils.get_moblab_id();
File "/usr/local/autotest/client/common_lib/site_utils.py", line 213, in get_moblab_id
with open(moblab_id_filepath, 'w') as moblab_id_file:
IOError: [Errno 13] Permission denied: '/home/moblab/.moblab_id'
Looks like it can not be created by apache user.
,
Jan 13 2018
,
Jan 16 2018
,
Jan 29 2018
,
Feb 7 2018
,
Feb 14 2018
The following revision refers to this bug: https://chromium.googlesource.com/chromiumos/overlays/board-overlays/+/07b8759fd2f58011ce1f361b623d81dbb858589e commit 07b8759fd2f58011ce1f361b623d81dbb858589e Author: Keith Haddow <haddowk@chromium.org> Date: Wed Feb 14 01:41:31 2018 [moblab] Generate moblab id when the homedir is created. Currently moblab id is generated on first use, this causes some race conditions depending on the code path of first access. To prevent this ensure the id is created just after the home directory ( where the id is stored ) is created. BUG= chromium:723865 TEST=local test and install Change-Id: I0d029fcf625fa8d45cb75410a79349dd58bb331c Reviewed-on: https://chromium-review.googlesource.com/906837 Commit-Ready: Keith Haddow <haddowk@chromium.org> Tested-by: Keith Haddow <haddowk@chromium.org> Reviewed-by: Keith Haddow <haddowk@chromium.org> [modify] https://crrev.com/07b8759fd2f58011ce1f361b623d81dbb858589e/project-moblab/chromeos-base/chromeos-bsp-moblab/files/init/moblab-homedir-init.conf [rename] https://crrev.com/07b8759fd2f58011ce1f361b623d81dbb858589e/project-moblab/chromeos-base/chromeos-bsp-moblab/chromeos-bsp-moblab-0.0.5-r83.ebuild
,
Feb 17 2018
|
||||||||
►
Sign in to add a comment |
||||||||
Comment 1 by haddowk@chromium.org
, May 18 2017Status: Started (was: Untriaged)