root运行google chrome

打开/opt/google/chrome 下的google-chrome文件,找到以下代码(我的系统是centos7 64位的,其它的系统没有测试)

exec -a "$0" "$HERE/chrome"  "$PROFILE_DIRECTORY_FLAG" \
  "$@"

在“$@”后面添加 --user-data-dir,以下为修改后的代码

exec -a "$0" "$HERE/chrome"  "$PROFILE_DIRECTORY_FLAG" \
  "$@ --user-data-dir"


鄂ICP备19018033号-1
0.061688s