How Do You Delete an Aurora Database when You Get an Error about It Not Being Started?

Problem scenario
You are trying to delete an Aurora database but you get this error: “This database is not started.” What do you do?

Possible Solution #1 (with the web console)
1. Log into the web console.
2. Go to “Amazon RDS”.
3. Go to “Databases”
4. Click on the Aurora cluster of the database you want to delete or its parent.

How Do You Find the Default Directory for Tomcat when It Acts as a Web Server?

Problem scenario
Your Tomcat server is has been configured to serve as a web server. You have access to the back-end Linux server. But you do not know what directory corresponds with the URL of the host. How do you find what the default directory is for files that are presented on the web?

Solution
From the back-end, run this: sudo find / -name index.html | grep tomcat

Look for a WEB-INF or webapps directory.

How Do You Troubleshoot an Error Such as “UnboundLocalError: local variable ‘foobar’ referenced before assignment”?

Problem scenario
You run a Python program. You receive this message: “UnboundLocalError: local variable ‘foobar’ referenced before assignment”

What should you do?

Solution
Initialize the variable (e.g., foobar = 0). If you do so inside a function wherein foobar is called, that may work. If you want it to be available globally throughout your program, you will initialize it outside of a function.

How Do You Troubleshoot Golang Using Hexademical Values?

Problem scenario
Your Golang program has variables with values that look like this:

{0xc4200457e8 [97 49]}

You think the that underlying variables should have regular alphabetic string values. What should you do?

Solution
Use the .string() function.

When you use strings.Builder for a variable, the value will be a hexadecimal value. To retrieve the string value that you intend,

What Are Some Free SQL Front-end Applications to Install on a Windows Desktop?

Problem scenario
You want a free trial or a completely open source (always free) graphical user interface application to install on your Windows desktop or laptop. What options do you have for a free front-end?

Answer
These GUIs are free or free to start out with an initial trial:

https://www.aquafold.com/aquadatastudio/trialregform
https://www.heidisql.com/
https://dbeaver.io/
https://www.devart.com/dbforge/postgresql/studio/
https://www.pgadmin.org/
https://omnidb.org/
Team SQL (formerly at https://teamsql.io/)
https://download.cnet.com/DbVisualizer/3000-10254_4-10202406.html
https://fishcodelib.com/database.htm

How Do You Know if Hadoop is Installed (and the version if it is installed) on Linux SUSE?

Problem scenario
You are administering Linux SUSE machines. You want to see if Hadoop is installed on them. The command hadoop version does not work.

Solution
Run this command:

sudo find / -name hadoop -type f

From the results above, you can probably find the file and path of the executable. It will likely not be in /var/ or /tmp/.

How Do You Troubleshoot the GitLab Installation Error “dpkg: error processing package gitlab-ee…post-installation script returned error exit status 1”?

Problem scenario
You are trying to install GitLab, but you get this error:

“dpkg: error processing package gitlab-ee (–configure):
subprocess installed post-installation script returned error exit status 1″

What do you do?

Possible solution #1
Is Jenkins running on the server? Is a service running on port 8080? Can you stop any process running on port 8080 and try again?

How Do You Troubleshoot “Errno::ENOMEM: Cannot allocate memory -” or Some Other “out of memory” Error in Linux?

Problem scenario
You go to /var/log/ for the program or application that is not working properly. You look for the word “error.” You see HeapDumpOnOutofMemoryError or “OnOutOfMemoryError=kill -9” messages.

Or you get this error on the terminal that says “Errno::ENOMEM: Cannot allocate memory.” How might you troubleshoot out of memory errors on Linux?

Solution

Possible solution #1
Add more memory,

What Are The Different Statuses of Individual Docker Containers?

Question
In Docker what are possible status values of containers?

Answer
Possible statuses include the following:

created, restarting, running, removing, paused, up, exited, or dead

Sources: 1) https://docs.docker.com/engine/reference/commandline/ps/ (for every one except “up”)
2) https://www.thegeekdiary.com/how-to-list-start-stop-delete-docker-containers/ (for “up”)

The docker create command when used with a Docker image ID will produce a new container in the “Created” state.