## Finding pairs of vertices which would disconnect a graph

Given a connected, undirected graph $$G$$, describe an algorithm which can determine if the removal of any pair of vertices would cause $$G$$ to become disconnected.

There is an obvious brute force solution, which is to just generate all pairs of vertices, produce new graphs with those vertices removed, and then test if that graph is connected using something like a BFS, running in $$O(|V|^3)$$ time.

However, I feel like this is not the intent of the question. We learned about an algorithm to find the articulation points of a graph, and it seems like something like this should be possible to determine if the removal of any pair of vertices would disconnect the graph, but I am not sure how it would be applicable.

## Minimum number of edges to remove to disconnect two node sets \$A\$ and \$B\$ in a directed graph

We have directed graph $$G$$ (not necessarily a DAG), two disjoint sets $$A$$, $$B$$, of vertices.
I need to plan an algorithm returning the minimum number of edges that need to be removed, such that there will be no path from any node in $$A$$, to any node in $$B$$ and vice versa.

I had the idea using max flow min-cut to find the minimum number of edges needing to be removed such that there won’t be a path from $$A$$ to $$B$$, and then using the algorithm again on $$B$$ (so there won’t be a path to $$A$$).
The problem is that the sum of these minimum number of edges isn’t necessarily the “global” minimum.

Does there even exist such an algorithm running in polynomial time?

## SharePoint mapped drives eventually always disconnect, requiring logging out/in via IE

In our corp environment, we are being required to move our file shares to SharePoint Online. In order to maintain some semblance of ease of use for the general user population, we’re trying to continue to use mapped drives. Bizarrely, Microsoft discourages this (no reason given why). We’re still gonna try.

Our procedure, which always gets things working in the short term:

• Add our SP site (`https://XXXXX.sharepoint.com`) to the Internet Properties Control Panel Trusted Sites list (using wildcards, e.g. `https://*.sharepoint.com` does not work)
• Open Internet Explorer (must be IE, not any other browser), log out of our SSO corporate SP site, close IE, reopen IE, sign back in, close IE
• Map the SP Document Library to a drive letter, e.g.

`net use T: https://XXXXX.sharepoint.com/sites/myteamfileshare.group /PERSISTENT:YES `

This works “for a while.” (It even survives logouts/reboots.) After some time period (around a week?), when a user logs back in, the drive has a red X over the drive icon in Windows explorer, and if the user tries to access that drive in Windows Explorer, they get this error dialog:

This error can be resolved if the user performs step #2 above (opening IE, logging out, closing IE, etc.), but that is an unacceptable workaround.

It unfortunately looks like this problem has been around for quite some time, in some form or another (cf. The network drives mapped to Sharepoint Documents Library cannot reconnect after login in Portal O365 and intermittent Error when Using File Explorer to access Sharepoint content)

Any methods to get a consistently mapped drive that doesn’t disconnect are very appreciated!

## having problem with open-connect reconnect after disconnect

im using open connect as VPN service on a headless remote pc with LUbuntu 19 and using ssh to remote connect. the ISP recently has some issues and i have about 2-5 times disconnects in every day life approximately 🙁 i use following command to connect:

``openconnect --reconnect-timeout 10 ... ``

problem is here that –reconnect-timeout does not work as expected and will be failed. i have several cron jobs that must use over vpn so i need a solution or script to 1st check the network ip or openconnect status and if its failed @ second face establish new openconnect connection.

## Ubuntu Printer disconnect

Today I installed Ububuntu 18.04 LTS on my system and everything worked fine, until I pluged in / installed my printer. When Im scanning more than 2 sheets of paper it suddenly disconnects from my pc and then reconnects so that my scan proccess is aborting. I dont know why its happening but it does. This problem doesnt occur when im using the drivers from the webite but then ubuntu reinstalls the printer everytime im plugging it in (1. printer= printer with driver 2. printer= printer with non working driver). Is there any way to fix this? Is it possible to somehow disable autodetect / autoinstall printers? If you want you can also have log files.

## How can I fix nohup, byobu, tmux, screen, etc to not die when I disconnect from SSH?

I’m running KDE Neon which is Ubuntu 18.04 Bionic (LTS) with the latest KDE desktop packages on top of it.

Since upgrading to this from Xenial I have lost the ability for processes to survive SSH session disconnects… specifically nohup, tmux, screen, byobu and all their children are killed when disconnecting.

Here’s a simple test to demonstrate the problem

``# connect over ssh cd /tmp nohup watch date & ps -ef | grep watch # disconnect and reconnect ps -ef | grep watch # process is gone ``

I tried reverting tmux and byobu to older versions before discovering nohup was also effected. This leads me to believe that it’s either SSHd config or systemd.

Apparently systemd decided to change it’s default behaviour to nuke all users processes when a user disconnects some time ago. I tried to revert the behaviour by editing /etc/systemd/logind.conf and setting KillUserProcesses=no and then rebooting (service systemd-logind restart didn’t work). It didn’t work… I’m at my wits end.

Help!

## Почему disconnect работает не правильно?

недавно я начал изучать socket.io. С помощью них я хочу отображать всех пользователей, кто сейчас находится онлайн. Вроде бы все получается, но вот только отключение пользователя работает не так, как запланировано. Логика такова: при посещении сайта, пользователь присылает свой логин на сервер, и тот записывает его в массив пользователей, находящихся онлайн. При выходе, логин пользователя удаляется из массива пользователей, находящихся онлайн. Но, при выходе одного пользователя, всех пользователей выписывает из массива. Из-за чего это происходит?

Server

``const users = [];  io.on('connection', (socket) => {     socket.on('global room', (global) => {          socket.login = global.login;         users.push(socket.login);          socket.join(global.room);          socket.emit('onlineUsers', users);     });      socket.on('disconnect', () => {         users.splice(socket.login, 1);         socket.emit('onlineUsers', users);     }) }); ``

Client

``var socket = io();  socket.on('connect', function(){      var room = 'global room';     var userLogin = \$  ('#userLogin').val();      socket.emit('global room', {         room: room,         login: userLogin     });      socket.on('onlineUsers', function(users){       console.log(users);     }); }); ``

## Drives randomly disconnect on USB Hub

When I try to read from multiple external desktop drives connected to a USB 3.0 hub it will work fine for a couple minutes before:

``[  462.908496] usb 9-2.2: reset SuperSpeed USB device number 8 using xhci_hcd [  469.467983] xhci_hcd 0000:02:00.0: xHCI host not responding to stop endpoint command. [  469.468235] xhci_hcd 0000:02:00.0: xHCI host controller not responding, assume dead [  469.468279] xhci_hcd 0000:02:00.0: HC died; cleaning up [  469.468366] usb 8-2: USB disconnect, device number 2 [  469.468401] usb 9-2.1: USB disconnect, device number 7 [  469.469441] usb 9-2: USB disconnect, device number 6 [  469.488016] sd 7:0:0:0: [sdg] tag#0 FAILED Result: hostbyte=DID_NO_CONNECT driverbyte=DRIVER_OK ``

shows up in dmesg and the drives disconnect. I’ve tried two different hubs and they both do this. When I connect the drives directly into the USB ports they don’t have this problem.

Here’s my kernel:

``4.15.0-51-generic #55-Ubuntu SMP Wed May 15 14:27:21 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux ``

I’ve tried disabling legacy USB mode in the BIOS and it still fails.

## How to disconnect an internal (“fixed”) USB device on Ubuntu 18.04?

When I type `lsusb` I see a list of connected usb devices. One of them is 0955:7002 – “Nvidia Stereo Controller”, which causes me a lot of problems. I want to remove the device but I really don’t understand how it works- is this a physical device that is connected internally? Is it a virtual device? Its “removable” attribute says “fixed”. Of course, needless to say, there is nothing connected to the external USB ports.

I work on a laptop with Nvidia GPU installed (I don’t think it has to do with my problem), and I have dual boot: Ubuntu 18.04 and Windows 7. On the windows side I can find the aforementioned device on the device manager and I can also disable it but I guess it is irrelevant to what happens on the Ubuntu side… (I tried “disable” just in case, with no success, and I don’t want to risk uninstalling)

Any information, even to understand the situation better (in the comments pls), will help.