How to kill one tab of google chrome using pid
You can't close a tab by killing the process. The process represents a renderer that the main browser uses the execute and draw a page, which it then copies to the screen. The "Aw, Snap!" is what the browser displays when the renderer responsible for that tab crashes or is killed. The proper way to close the tab would ideally be via a command-line switch, but there is none that I know of at this time.
You can't kill tabs by PID. Here's the next-best thing: it's possible to kill an unresponsive tab (or set of tabs) by interactively navigating to Chrome Task Manager in Chrome:
- Hamburger Icon (three lines in top-right);
- More Tools;
- Task Manager and clicking on the tab name;
- Then clicking the "End Process" button at the bottom.
This may be helpful for you. Probably a whole bunch of Chrome windows/tabs have become "unresponsive".
If you go to the Windows GUI Task Manager and kill the ProcessTree of all the Chrome.exe 'processes' eventually, you will click on one, that will kill all the Chrome Windows & Tabs. then if you re-open Chrome, you'll get a tan colored bar that asks if you want to restore the previous pages, that will reopen everything you had before.
Problem with this issue: Time consuming, if you go to admin CMD window and issue a taskkill
command to '/F' (forcefully) kill everything with the imagename of CHROME, they will all die instantly, but when you reopen Chrome, it won't remember anything or ask if you want to restore anything; unless you kill the one 'master' PID of the ChromeBrowser itself. I can't find anything unique about that process to kill it without having to lookup it's dynamic PID every time.
My solution:
- RightClick in the Chrome "Title-Bar" and choose: "Task Manager" (the Shift+Esc shortcut, is slower, and often doesn't work). At the top of the list, you'll see "Browser" with a chrome icon. This is the only entry you can't select and click on [End-Process] in the column, find it's "Process-ID"
- From an ADMIN-CMD Window issue this command: taskkill /F /FI "PID eq _ _ _ _" (fill in the blanks with the PID) Then Chrome will die almost instantly, and when you reopen, it will offer to restore previous pages.
- the easiest way to handle this is with a batch-file using the "SET /p" feature to allow you to just type in the PID number in order to make it run, more or less automatically.
The message you see is the one that you are supposed to see if a tab is killed. That tab is not using any memory or resources of any kind until you reload it. If you have 3,000 open tabs and all but one are killed (and therefore have this message), your computer will run smoothly. If you want to close the tab and lose the URL and cached information, the just close it. With the 'X'.