ASP.NET exceptions in AWS Linux - asp.net

When I run ASP.NET 5 in Windows, and it throws an exception, I can view the entry in the Windows Event Viewer. I have deployed my site in a Docker container to Amazon's ECS, so it's running in Linux now. Where should I look in Linux to similarly view such entries?
I am trying to troubleshoot an error when I communicate with RDS, but it only occurs when I'm looking at it Linux, not when I run the site in the Visual Studio debugger.

As it turns out, the Docker log can be viewed with the following command
docker logs ad7629ef8bc | less
where ad7629ef8bc is your desired container ID. less redirects the output to a scrollable UI. To exit the UI, and return to the prompt simply press the q key. I also found a lot more documentation on less and other output options at http://linuxcommand.org/lts0060.php.
You can find a list of all Docker commands at docker --help.

Related

ACORE API, assistance with errors and deployment

I'm having trouble with setting up ACORE API's and then having them work on a website.
Background:
Azerothcore running 3.3.5 on a debian standalone server, this has the Database, Core files and runs both the world and auth server basically a standard setup that is shown in the how-to wiki.
I also have a standalone web server, on the same subnet, but it's a separate server running linux and normal web server stuff, this has a wordpress installation with azerothcore plugin for user signup etc.
I'm trying to add the player map (https://github.com/azerothcore/playermap) and the ACORE-API set of functions (server status, arenastats, BG que and wow statistics) (https://github.com/azerothcore/acore-api)
Problem:
I understand the acore-api must be run in a container (docker or whatever) on the server, which I have done and it binds to port 3000, I can then go to the local ip:3000 and it brings up this error. (all db's etc are connecting and soap is working)
error 404 when navigating to IP:3000
I do get a few errors when running NPM install seen here: I'm not sure if they would be causing any issues or not.
screenshot of NPM errors on install
But further that, when I put say 'serverstatus' on the webserver (separate server) and configure the config.ts file I can't seem to get anything to display.
I'm not sure what I'm doing wrong but is the same scenario for all of the different functions for the acore-api
How are these meant to be installed and function? I feel I'm missing a vital step.
Likewise, with PLAYERMAP I have edited the comm_conf.php and set the realmd_id, but when loading the page, I do get the map, but the uptime is missing and no players are shown?
Could someone assist if possible?
Seems like an issue with NodeJS version. Update your NodeJS to latest LTS version 16.13.0 (https://nodejs.org)

Can cloud instances of Jupyter Lab support pop out interactive windows

I'm new to Jupyter notebooks/Lab and I've successfully got interaction with pop-out windows and buttons etc with ipywidgets on local instances of Jupyter Lab but not in the cloud when using notebooks.ai - the code runs without error but doesn't create the appropriate windows/button.
Is there anyway to get this working or is this an inherent restriction of using Jupyter Lab in the cloud?
I'm wondering whether there are firewall settings that need configuring to get this to work?
The X11 forwarding is disabled on the docker machines provided by notebooks.ai. Hence, any pop-up interaction is not being forwarded to your machine. However, you can see any inline plot/button in the Jupyter notebook.
If you are interested in this feature there is a GitHub repository to request features (I have never tried it) but might be interesting for you to receive a more in-depth explanation, workaround, or solution.
PROVE:
In the launcher tab you can either run a notebook, a python interpreter or a terminal on the remote docker machine. If you select the terminal and type echo $DISPLAY, you will see that the result is an empty line (if a valid display was attached you will see something like: DISPLAY=localhost:11.0).
For further information about using BASH to check if X11 forwarding is enabled from SSH check this question.

Error 502 (Bad Gateway) when accessing Jupyter Notebook from Google Deep Learning VM

I have recently quoted a Deep Learning VM from Google Cloud. DLVM provides a link to the jupyter notebook of our VM, but when I paste the link to the browser, it gave us Error 502 (Bad Gateway).
The VM consists of 100 GB of memory, 4 vCPU (26 GB Memory), and 2 Tesla T4 GPUS. I tried to stop and restart the instance several times but it did not work.
The link to Jupyter Notebook is provided by this command given by the "Get started" page:
gcloud compute instances describe --project <project-id> --zone <zone-id> <instance-id> | grep googleusercontent.com | grep datalab
The command successfully gave me a link.
However, when I paste the link to the browser, it gave me an error as followings:
Error 502 (Bad Gateway)!!
502. That’s an error.
That’s all we know.
Restarting the Jupyterhub server will resolve this error
It is hard to debug the problem based on just this information.
Some things to try:
try opening the link in the incognito mode (after clearing the cookies) and sing in with Google Account
make sure that your user has Project Editor permissions on the GCP project
try to create notebooks via our new UI: https://console.cloud.google.com/mlengine/notebooks/instances
let me know if any of this helps, if not please ping me directly I can assist with debugging.
I had the same problem and here's what I found helps. If you deploy the DLVM with specs that are same as or above the default, i.e
Machine type : 2 vCPUs with 13GB memory and 1 GPU
it won't crash. Any config less than this, gives me the same error as you. I can't get anymore info or logs on the error nor do I know if lesser configs are actually below the minimum system reqs for the DLVM but this will definitely let you use the DLVM seamlessly.

Dart Pirate Tutorial Doesn't Download JSON after build (step 7)

I did the Google Dart tutorial (pirate name badge: https://www.dartlang.org/codelabs/darrrt/) all the way through and it ran exactly as expected until I hit step 7 where I run the build on my normal browser.
What happens is the page loads, but it never seems to complete the async download of the JSON file, so the input and button never become enabled and Chrome keeps spinning because it's waiting on localhost (127.0.0.1).
I imagine this is because I'm not running a web server?
What would I have to do to get this sample app to run on my local machine?
Thanks!
Browser: Chrome 42.0.2311.90
OS: Mac OS X 10.10.3
Why are you not running a web server? You could just run pub serve web from the package folder (where the pubspec.yaml file is) and load the page from http://localhost:8080/piratebadge.html.
Your <Dart-SDK>/bin directory needs to be added to your systems PATH in order to make pub serve web work.
If you use DartEditor just use the run context menu on the piratebadge.html file and it launches pub serve automatically.
This appears to be a new bug in the DartEditor on Mac (and Linux), see https://code.google.com/p/dart/issues/detail?id=23431&thanks=23431&ts=1431391466
One way to work around this is to start your own http server, e.g. 'python -m SimpleHTTPServer' in the build/web directory and then goto http://localhost:8000/piratebadge.html.

Why don't QLocalSocket/Server connections work when one process was invoked by an NSIS installer?

I have an NSIS installer that installs my Qt application. At the end of the install process, the installer gives the user the option to launch the application immediately.
My application uses QLocalSocket/QLocalServer to talk to other local instances of the application. (They talk to each other basically just to ensure that there's only one instance of the app running at a time.) However, on Vista, if one of the instances was started up by the installer, then other instances cannot talk to that instance unless they were also started by the installer (or uninstaller, interestingly).
The NSIS installer launches the app with the Exec command. The client tries to connect to the server through QLocalSocket::connectToServer, which fails with the error "QLocalSocket::connectToServer: Unknown error 5".
Can anyone explain this? What's the best way to work around it?
If 5 is a windows error code, it would mean access denied. Is there a way for you to change the security on this server (You would need to access the native pipe handle)?
The finish page run option has more issues than just this, the new process gets the wrong HKCU and user profile etc.
I would recommend just disabling the run checkbox on the finish page. (This issue goes all the way back to win2000 when RunAs was added)
If you really really want this run checkbox, you can use the UAC plugin, it will allow you to start a child process as the "correct" user.
Finally figured this out. The installer was running as admin (the install script said "RequestExecutionLevel admin"), and apparently it launched my app with those elevated permissions, which meant that other instances of my app running with user-level permissions couldn't connect to it. QLocalSocket/Server uses named pipes on windows, so I figure this is a windows security feature. I'm planning to work around this by using the UAC NSIS plugin, which I believe lets you run a process with user-level permissions.

Resources