RabbitMQ: List Queues – Rabbitmqctl

RabbitMQ is a message-queueing software also known as a message broker or queue manager.

Queue in RabbitMQ is the buffer that stores messages, while message is the information that is sent from the producer to a consumer through RabbitMQ.

In this note i will show how to list queues in RabbitMQ from the command-line using the rabbitmqctl command. (more…)

RabbitMQ: List | Create Users – Rabbitmqctl

The internal RabbitMQ users can be managed from the command-line using the rabbitmqctl command.

Note, that the users from any alternative authentication backends (e.g. LDAP) cannot be inspected or managed with the commands listed below.

In this note i will show how to list, create, set permissions and delete internal RabbitMQ users from the command-line using the rabbitmqctl command. (more…)

RabbitMQ: List | Create vHosts – Rabbitmqctl

Virtual hosts or vHosts in RabbitMQ allow to segregate applications using the same RabbitMQ instance by providing logical grouping and separation of resources.

If you are familiar with virtual hosts in Apache or server blocks in Nginx, the idea is similar.

In this note i will show how to list, create and delete virtual hosts in RabbitMQ from the command-line using the rabbitmqctl command. (more…)

Jenkins: Reset Admin Password

If you have forgotten the Jenkins admin password and can’t log in to a Jenkins user interface (UI) as administrator, you can connect to a Jenkins server via SSH and reset the Jenkins admin password.

The simplest solution is to completely disable security in /var/lib/jenkins/config.xml file, access the Jenkins UI omitting authentication and rest the Jenkins admin password. (more…)

Jenkins: Default Password & Username

The first time you start Jenkins, the configuration is created along with the initial default administrator account.

If for some reason you have skipped the user-creation step in the setup wizard, you can use the default admin username and password to access the Jenkins UI.

The Jenkins default password is stored in the $JENKINS_HOME/secrets/initialAdminPassword file (the exact location of the Jenkins default password is indicated in the Jenkins console log). (more…)

Git: Detached HEAD – Go Back – [Fixed]

“You are in ‘detached HEAD’ state” is not an error message and is nothing to be worried about.

This state means you are no longer on a branch, and it happens when an arbitrary commit is checked out instead of a branch.

If this state was unintentional and you want to “fix” the ‘detached HEAD’, you can go back to the branch you are expected to be on by runing the git checkout command. (more…)

Windows: Shutdown/Reboot Event IDs – Get Logs

While troubleshooting an issue that causes an unexpected reboot or shutdown of a Windows machine, it is important to know which event IDs are related to system reboot/shutdown and how to find the appropriate logs.

In this note i am publishing all the event IDs related to reboots/shutdowns.

I am also showing how to display the shutdown events with date and time, using a Windows Event Viewer or from the command-line using a PowerShell. (more…)

Oracle: Get Database Server Host Name

In Oracle, it is possible to get a database server host name using a simple SQL query.

In this note i will show how to SELECT the Oracle database server host name you’re currently connected to, using the SQL query that doesn’t require any special permissions.

I will also show how to get the database name, the current schema/user and the name and IP address of the host machine from which the client has connected. (more…)

Oracle: Show Tables – SQL*Plus

Tables are the basic unit of data storage in Oracle databases.

In this note i will show how to list all tables in an Oracle database (equivalent to SHOW TABLES command in MySQL) using the command-line interface of SQL*Plus.

I will also show how to list only tables owned by the current user, show the tables that the current user has access to and how to show the tables owned by the particular user or in the particular schema. (more…)