Persistent jupyterlab page on web browser - windows

In linux, there can be dedicated jupyter lab port that is always available. User does not need to launch Jupyter Lab from terminal.
How can something similar be achieved in windows. So that even if I restart my machine I still can visit the page and expect jupyter lab to be running.
Kindly note I don't want to use jupyter-lab desktop instead.
Basically I want a bookmark saved and when I open the page it automatically triggers a live jupyter lab workspace as is the case in linux ports.

Probably in Linux kernel based OS, JupyterLab is converted to a service. You can check all services with systemctl --type=service --state=active command. In Windows, if you want a similar experience to enabled services of a Linux kernel based OS, you can easily create a new startup item. To do that:
1- Create a shortcut with the command that you use to start JupyterLab:
a. Right click to an empty part of your desktop -> New -> Shortcut
New shortcut creation
b. Write "C:\Windows\System32\cmd.exe" /k <terminal_command_for_jupyterlab> to shortcut's location.
JupyterLab command shortcut
This shortcut will run the command for JupyterLab. Give an appropriate name to your shortcut.
2- Add this shortcut to startup items:
a. Press Win+R buttons.
b. Write shell:startup to Run window.
c. Copy your shortcut and paste your shortcut to folder that is opened with previous step.
After all these steps, JupyterLab should be started automatically without user interaction on each startup of Windows.

Related

Can I have multiple Powershell Consoles in one window?

So, now I have many open apps, often 3-4 powershell consoles. I'm able to order the powershell windows to watch them together (top left, top right, bottom left, bottom right).
So this means that if I switch to another app, when I switch back I have to restore all multiple powershell windows to see them all again.
What I want is, to create only one 'shared window' for many powershell, because when I need one, I need all of them to see.
Is there a way to do this?
Just to add more details about Windows Terminal approach:
Open a Windows Terminal
Type Alt+Shift+= or Alt+Shift+- to open a new Pane in the same tab
Type Shift+Ctrl+W to close the current Pane
If you need more details or modify the settings, go to next page Panes in Windows Terminal
ConEmu has this option.
You can also configure it to open as much consoles as you want when it starts.
ConEmu website
Enjoy!
VSCode can have Multiple Terminals which is the closest to this I've seen, quoted from documentaion:
You can create multiple terminals open to different locations and easily navigate between them. Terminal instances can be added by hitting the plus icon on the top-right of the TERMINAL panel or by triggering the Ctrl+Shift+` command. This creates another entry in the dropdown list that can be used to switch between them.
You can also split the terminal by triggering the Ctrl+\ command or via the right click context menu
Windows now provides the Windows Terminal.
Windows Terminal can split the terminal into panes and can also run different shells (i.e. cmd, powershell, and bash through the wsl)
You can install Windows Terminal directly from the Windows Store.
Create a virtual machine where you can run your PowerShell sessions uninterrupted. The PowerShell windows are always where I placed them when I come back.
It could be an expensive solution depending on your needs, but I have been doing this a long time. It's a robust solution since the only user processes on the VM are my PowerShell sessions.

Launch Jupyter Notebook in windows without command window

Is it possible to launch jupyter notebook without command console, i.e, without typing jupyter notebook and having a command window in your opened programs. I have made a batch file which I double-click to open the jupyter notebook. However, this step opens a command window and prints all the communication between jupyter and python processes. I want to eliminate this commandline window.
Instead of a batch file, one can use a shortcut.
To hide terminal you can run python scripts with pythonw.exe instead of python.exe. So I changed the Jupyter shortcut which was created after Anaconda installation accordingly. Mind that shortcut's Target field may have multiple python.exe instances, like the following:
C:\ProgramData\Anaconda3\pythonw.exe C:\ProgramData\Anaconda3\cwp.py C:\ProgramData\Anaconda3 C:\ProgramData\Anaconda3\pythonw.exe C:\ProgramData\Anaconda3\Scripts\jupyter-notebook-script.py "%USERPROFILE%/"
Shortcut window screenshot
This thread seems to be the first to appear when googling the problem.
My solution is for Anaconda users: Launch Jupyter from the Anaconda navigator. You won't have to keep an open CMD window, as upon exiting the navigator you are given the option to close or not close Jupyter.
It appears from the following questions that what you want to do is tricky in windows:
https://superuser.com/questions/62525/run-a-batch-file-in-a-completely-hidden-way
How to call CMD without opening a window
Each of these questions has various work-arounds presented in the answers, each with their pros and cons. Perhaps one of them will meet your needs.
I use RBTray to right click the minimize button and have the window go hide in the system notification tray.

Windows 2008 Remote Desktop will not copy+paste

I have just set up a Guest Windows 2008 R2 Standard Edition 64bit (VirtualBox on Windows 7 64 bit host) for some testing.
I have found that while "inside" the remote desktop environment (i.e. I remote onto the guest ip from the host) that copy and paste does not work. When I say "does not work" let me be explicit.
Assume I am logged onto the Win2008 machine via RDC
Nothing is in the copy/paste buffer. I can mouse click some text and then rclick copy. I can then right click and click "paste" but nothing happens. I can see the "choice" is enabled to paste bu nothing happens. The caret stays put.
CTRL+C / CTRL-V / CTRL-X does not work in RDC land
I am not talking about going in-between copy/paste RDC land/host land.
HERE is the double whammy: when I do the above it then "infects" my host pc so that copy paste is unavailable there too. if PRT SCR doesn't work any more.
I have tried:
restarting the guest os and host os
in group policy editor I have disabled "do not allow clip board redirection" ( I can't give you the full path to this copy/paste just broke again)
I have made sure that in RDC "options" for local resources include clipboard.
NB: if I don't touch RDC at all and log into the guest OS via the console copy paste works perfectly
Kill the rdpclip.exe process using the Task Manager. Then, create a new process named rdpclip.exe. This will solve your problem.
Follow these steps in Remote Machine.
Stop the rdpclip process
Open Task Manager.
Go to process tab and find rdpclip
Choose rdpclip and End that task.
Start rdpclip.exe
Go to start menu and open Run command
Open rdpclip.exe and click Ok button.
Copy paste should work now.
it appears this is a flaw with VirtualBox
these posts covers it
https://forums.virtualbox.org/viewtopic.php?f=6&t=44498 (read the last post)
https://github.com/FreeRDP/FreeRDP/issues/230
(In VirtualBox) SETTINGS->GENERAL->[Advanced]->Shared Clipboard {disabled}
There are multiple things to check.
Restarting rdpclip.exe is a worthy try if the copy/paste fails sporadically, meaning we might on a process in a previous session.
On the client side, we check the RDP Options. Click on the Show Options button in the bottom, pick the third tab Local Resources. Make sure Clipboard is checked.
On the remote server side, we want to check Remote Desktop Session Host Configuration (Win Server 2008+).
Double click the connection to open its Properties window.
In the tab named Client Settings, Make sure Clipboard is not disabled.
We need to log off from the remote desktop.
Workaround
Use an online shared text box like this one:
https://pastebin.com/

How can I see which processes/programs are sending/recieving data over internet in XP?

Is it possible to write a script to see which processes/programs are sending/receiving data over the internet in Windows XP? I have full administrator rights and I want to find a way to monitor data exchange on my machine without installing any additional software.
Step One: Windows XP
Open up the Run box by pressing the Windows key and R at the same time.
Put in CMD and press OK. The command prompt window will open up:
Step Two
In your open Command Prompt window, enter the following:
netstat -b 5 > activity.txt
and hit enter. (Note: to paste something into Command Prompt, you'll need to right click and click paste.)
If you forgot to run the prompt as an administrator (like I did in the screenshots above), just redo step one You can tell when it's running as administrator because instead of saying C:\Users\Username it says C:\Windows\system32.
If you've pasted the code right, a blinking cursor will... blink.
After a few minutes, press Ctrl+C. That'll stop the command.
Now type in command prompt activity.txt to open the log:
When you press Enter, your default text editor-probably Notepad-will open:
Now, scroll through the lists. You'll see that it's mostly your browser-but some times, there are programs like Google Talk's webcam program installed that call home even when you aren't using them.
Now that you've found any and all culprits that are programs accessing the internet (with and without your knowledge), you can either close them from the Task Manager or even uninstall them.

New OSX User: Opening up a new terminal window in current space(?)

I'm just meddling with OSX after a few years on Linux. There's a lot that I'm liking, but one thing that's slowing me down is that if I run the 'terminal' command via shortcut/spotlight/quicksilver, it whisks me off to any existing terminal in whatever space already has a terminal instance open.
I regularly like to pop up a terminal, run a quick command and then close it again, all the while staying in whatever desktop space I happen to be on.
...So, how do I do that on Mac?
Cheers...
Go to System Preferences -> Exposé & Spaces -> Spaces and check When switching to an application, switch to...
Download this tool called Visor
It lets you quickly get a tabbed drop down terminal using a hotkey like Ctrl-`.
Insanely convenient for working in the shell.
Try this tool: https://github.com/nmadhok/OpenInTerminal
This is a really handy tool for programmers on Mac as it lets you open the folder directly in Terminal. You can select multiple folders to open them in multiple terminal windows. You can also select files to open the parent directory in Terminal. This application works with Finder as well as without Finder which is a plus!

Resources