Chrome locks up in Linux

UPDATE 4-5-20: Same issues continue with the added feature that Chrome completely freezes up and won’t die even with kill -9 until I find the parent process. So back to Firefox. Kinda weird that a multi-billion dollar company can’t be bothered to make a stable browser for Linux. Guess we’re the redheaded stepchild.

None of the “fixes” like using flags when opening Chrome make any difference.

Reference my earlier post from December 2019

Here is how to get the broken Chrome window to die:

jw@PC:~$ ps -A|grep chrome
11992 ? 00:00:32 chrome
12001 ? 00:00:00 chrome
12005 ? 00:00:00 chrome
12025 ? 00:00:05 chrome
12027 ? 00:00:01 chrome
12043 ? 00:00:00 chrome
12073 ? 00:00:14 chrome
12177 ? 00:00:00 chrome
12204 ? 00:00:00 chrome
12275 ? 00:00:00 chrome
12304 ? 00:00:00 chrome
12333 ? 00:00:00 chrome

jw@PC:~$ kill -9 11992

Kill the earliest process in the list. I find that I have to use the “-9” option also.

Firefox won’t play MP4 files

I noticed after Chrome stopped working in Linux and I switched back to Firefox 71, that FF would not play a lot of videos or GIFs. This was true on some YouTube videos, all of Vimeo, and even locally opened MP4 (h264 with AAC audio, or h265, either HD or 4K) files I made. These files play fine on VLC. Apparently there is some kind of patent issue with MP4, and it would require that they pay something to the patent holder. Here is a link to the Mozilla page that alludes to this:
https://support.mozilla.org/en-US/kb/html5-audio-and-video-firefox

This may also relate to the problem I’ve seen with animated gifs, but I’m guessing.

It would have been nice for them to simply state that Firefox will not play MP4 files.

corrupt

It isn’t related to plugins or adblockers. I dug around for a few hours reading various suggestions from years ago all the way up to a few months back. There were several saying “Oh, just clear your cache and cookies”. Bullshit! This has to do with FF not knowing what to do with a particular format.

I recompiled ffmpeg and a bunch of libraries, but that didn’t help Firefox. I hate that I have to guess at why the latest version of a modern browser can’t play common video types. If Mozilla would state exactly why they won’t play certain types of files on their knowledgebase, that would be helpful. Or tell us what steps to take to enable the browser to play those files. As I said, other programs on the same computer play them with no problems, that reduces the issue to Firefox.

I purged and reinstalled Firefox entirely using these steps:


sudo apt purge firefox

sudo rm -rf .mozilla

sudo rm -rf .macromedia [remove vintage Flash player stuff. May not exist.]

sudo rm -rf .adobe [remove vintage Flash player stuff. May not exist.]

cd .cache
Delete the mozilla folder

cd /etc
sudo rm -rf firefox

cd /usr/lib
sudo rm -rf firefox
sudo rm -rf firefox-addons

Reboot your computer to get rid of any temporary files.

sudo apt install firefox

Firefox still is not able to play MP4 files. Ridiculous!

I also checked the steps in this StackOverflow posting and it made no difference, Firefox still insists that all MP4 files are “corrupt”.

Chrome won’t open in Ubuntu

UPDATE 4-5-20: Same issues continue with the added feature that Chrome completely freezes up and won’t die even with kill -9 until I find the parent process. So back to Firefox. Kinda weird that a multi-billion dollar company can’t be bothered to make a stable browser for Linux. Guess we’re the redheaded stepchild.

UPDATE 12-27-19: The issue of Chrome not opening seems to be related to two files called “Preferences” and “Network Persistent State” (maybe just Preferences) found in the home hidden directory .config/google-chrome/Default/ If I set these two files to be owned by root and not writable by my own login, then Chrome will open, but will not remember any extensions or settings I configured the last time I used Chrome. If I set the same files (via chmod and chown) to my login and permissions to read+write, then Chrome will not open. I just see the spinner on my cursor indicating it is trying to open, but then I have to kill the process via terminal. I sent this info to the Chrome developers via a popup in Chrome when it couldn’t read my Preferences.

UPDATE: Still no real explanation for why Chrome works fine for several months and then stopped. Also, no explanation for why some of these “fixes” work once or twice and then stop. If I start with a completely new profile, it will work again for a while. This makes me think there is some setting that is being changed that breaks it, but no idea what since it works fine and then suddenly won’t open.

Well, my “fix” worked once before doing the same behavior again. I have to find the process and harshly kill it.
ps -A|grep chrome
kill -9 process number

jw@JW-PC:~$ ps -A|grep chrome
9855 ? 00:00:00 chrome
9864 ? 00:00:00 chrome
9868 ? 00:00:00 chrome
9888 ? 00:00:00 chrome
9891 ? 00:00:00 chrome
jw@JW-PC:~$ kill -9 9855

I set my environment variable “MESA_GLSL_CACHE_DISABLE=true”, based on a Debian bug site statement, and that worked one time for opening Chrome. Thereafter it reverted to not opening at all. Frustrating!
To set the environment variable type this:
export MESA_GLSL_CACHE_DISABLE=true

Another site said to start Chrome via terminal and type
google-chrome --disable-gpu --disable-software-rasterizer

That worked a few times, but then gave the error
ERROR:gpu_channel_manager.cc(450)] ContextResult::kFatalFailure: Failed to create shared context for virtualization.

So I tried various other option flags that worked for others, but no luck for me.

(Original Post)
Recently Chrome began acting up on my system, as in it simply would not open. The process was running, but it would not display. If I ran google-chrome from a terminal, I saw an error about sandboxing:
ERROR:sandbox_linux.cc(372)] InitializeSandbox() called with multiple threads in process gpu-process

I used Firefox to go online and search for the error. I found a Debian bug site that mentioned that changing the configuration of the mesa graphic drivers could help. I was not able to find a config file for these drivers, but found that I could add the repository for the drivers and get the latest version. That fixed it for me.

Here is the site with info on adding the repository:
http://tipsonubuntu.com/2019/02/08/install-mesa-graphics-driver-18-3-3-ubuntu-18-04/

I went from version 19.0.8 to 19.2.1 and Chrome opened right up. Wish I’d seen this fix before blowing away my old profile…

Old systems support

One of the facilities I support still uses Windows XP for door controls. It never has to see the Internet, so there is not much danger in that approach. However, the hardware is old. And new computers won’t necessarily be able to run XP. Even if I can migrate the OS, the hardware simply didn’t exist when XP SP3 was the rage.

So, I do what I can to keep some old IDE drives around, and a few old PCs of the type they have been using for nearly 20 years. I clean out the dust, and occasionally get called because one is acting up. I was recently working on one where I used some command-line code, and the worker commented “Did you just CODE?! Wow. I think our techs have to be great to support such ancient equipment.” I’m always surprised when techs don’t know the old DOS commands and keyboard shortcuts.

Here are just a few that I use even on all Windows systems:

chkdsk /f c: (makes the system check the current quality of the C: drive, and fix anything it thinks is wrong. This often requires a reboot since C: is in use.)

defrag c: (checks the fragmentation level of the drive and defragments it, if needed)

ipconfig /all (show the IP address, MAC, and other networking information)

Some basic ones for getting around in a command window:
dir (lists the files in the current folder, which used to be called a directory)
cd (change directory, change folder)
del (delete filename)
exit (closes the command window)

Another Windows based tool I use is Disk Cleanup. Occasionally, even after that I’m fighting for every bit of disk space I can free-up. I’ve found that the CBS log file can get to be several gigs, and so I delete that if I’m running out of room.
From the command console,
1. net stop trustedinstaller
2. net stop wuauserv
3. delete the CBS.log file (and other files in that folder)
4. net start wuauserv
5. net start trustedinstaller

Modern Windows is getting better at taking care of itself. But on these old systems, knowing some old commands can keep a facility operating and my customers happy.

On Linux systems, one of the best tools that a tech can have (and know how to use WELL) is “vi”. It is an editor that will function when all of the higher level editors will not. It can save your bacon to know it, and can give you an extra paycheck as a consultant when a company sysadmin doesn’t know it and is in a panic to fix a system he/she just hosed. Take time to learn and use it so that it is simple for you.

RANT: Motherboard Companies, What are the actual differences in your product lines?

I’m in the market to build a new PC, one that is mainly going to be stressed by editing 4K video. Other than that, the tasks are mundane. All my games are 1980s vintage, and my Internet is about 240Mbit down, so I don’t need 2gig LAN or a motherboard that cycles through colorful LED displays. I’d honestly prefer a dark silent computer.

So when I go to a company website like Asrock and I see multiple lines of motherboards, I reason that they have some kind of significant difference between the lines. I get that some are processor specific, but why do I have to dig to find out why a company chose to make so many different kinds of motherboards? Be more obvious about WHY you made “Phantom Gaming” vs “Steel Legend” vs “Taichi”. Throw me a bone, give me a clue, otherwise I spend a lot of time sorting through specs, and not really knowing what motivated them to create these separate lines, of why I should prefer one above another. And put that right up front.

So, I use a third-party site to get the best specs on what a great 4K or better video editing computer should have, and why. That site is https://www.cgdirector.com/best-computer-for-video-editing/

That way I can have my most important specs in a list, as well as some examples of boards and processors to consider. But I still have to sort through the specs on various sites.

Review of ToteVision LED-710-4KIP test monitor for IP cameras

I needed a portable field unit for setting up IP security cameras that I install. It needed to have POE, a good battery, and a good screen so I can see the video clearly and any camera menus.

I tried out the ToteVision LED-710-4KIP based on the feature set it has. It has several tools such as cable testing, POE voltage testing, and various camera tests.

It has some interesting features for setting up cameras, such as detecting camera IP and auto-setting itself to the subnet range of the camera.

But the primary purpose of using it to set up IP cameras in the field doesn’t work because the buttons it has for focus and zoom do not work with all cameras, even ones that have ONVIF (as almost all do these days).

I connected it to a Samsung SNV-6084 dome camera (about 2 years old), and it was able to find the camera’s IP address and take me to a login screen. It brought up the live video, which was out of focus. I tried the various physical buttons such as Near, Far, Tele, and Wide, but none of them had any effect on the camera.

I tried it on two Vicon cameras, and the live video screen would instantly close as soon as it tried to show video. That makes this unit useless to me.

I was able to go to a webpage in Firefox on the unit (I just happened to know the URL for focusing on this camera) and it brought up controls that I could use for focusing, but no image. That is another problem with this unit. If the IP camera requires a plugin such as Silverlight in order to view video on submenus, then there is no way to get the plugin to load and function on the ToteVision unit. The built-in menus have buttons specific to Hikvision cameras, so perhaps it was designed around their use rather than other brands, but nothing in the literature suggested this.

Those problems make this unit useless to me. I’ve used cameras from other companies that also require plugins to view video and make changes to the cameras, so this isn’t an uncommon situation. Camera makers are starting to move away from plugins, which is good. But I have so many cameras in the field already that I have to be able to use plugins. This puts me back to using a laptop and a POE switch instead of a more portable unit.

Summary:

  • Unit seems designed around Hikvision cameras
  • Control buttons don’t work on Samsung or Vicon cameras
  • It has interesting features that would make it great, but since the most basic don’t work with my cameras, the unit is pointless.
  • The manual was incomplete and was clearly written by non-native English speakers, A section showing a screen shot of “live video” shows an icon for needing to install a plugin, the very issue I had with Samsung cameras, but no mention of it in the text of the manual.

Q-SEE QCN8099B camera pinout

I had to work on an IP camera that had the pigtail cut off. It is a Q-SEE (Hikvision) QCN8099B camera, and had a pigtail with an RJ45 jack built-in. However, the wire colors that the company used inside the camera were not the standard colors normally encountered in CAT6 cabling. And there were only 6 wires instead of 8, and the wires were very thin which meant I couldn’t punch them to a jack directly because they were too fragile.

I figured out that there were two pairs being used for communication, and one pair being used for POE.

cam wires3

I cut apart the remains of the jack which still had wires attached to it.
IMG_0826

From this, I determined which colors went to which pins, and used a cross-reference to the T568B standard to figure out how to splice the wires to a CAT6 cable.


CAMERA T568B POE-B
1 BROWN ORN/WH
2 PURPLE ORN
3 ORANGE GRN/WH
4 YELLOW BLU DC+
5 (NONE) BLU/WH DC+
6 BLUE GRN
7 GRAY BRN/WH DC-
8 (NONE) BRN DC-

I taped the ends of the CAT6 cable and camera cable together to remove stress from the individual wires. I used 3M Scotchlok UY2 connectors to splice the wires of the CAT6 cable to the wires of the camera. (I didn’t get a picture of the splices)

Initially, I tried connecting the resulting cable to a POE switch to see if it would recognize the camera. But Q-See likes to keep things proprietary, so I drove back out to the location of the Q-See NVR and plugged the cable into the unit. After a minute or so the camera came up!

I found no pinout documentation online, nor any info about a default IP address for these cameras. It appears that they were made for use only with their own brand NVR. I’ve seen other blurbs that say “Just type in the IP address into a browser”, but that assumes I know if it has one, and what the address is.