Posts Tagged ‘name’

Saint Martyr Kirana of Solun (Thessaloniki) a Bulgarian macedonian saint martyred on 28 February 1751

Tuesday, February 28th, 2023

saint_Kyranna-of-Thessaloniki

Saint Martyr Kirana (Kerana) was born in the first half of the 18th century 1731 A.D. in the Thessaloniki village of (Ossa) Avisona, in the family of pious Christians in Ottoman Macedonia which at that times was highly inhabited with Bulgarians who held that name of the time, and even today many Bulgarian have this archaic name.

A slim and beautiful girl, she was taken by a janissary (stolen kids from Bulgarian or other non-turkish nations who were grown and included in the Ottoman empire’s governance or army) who was a subashiya (tax collector who collected 10% of all the non-turks income) in her village with the idea to make her one of his wifes. After Kirana rejected him, he abducted her with a gang of janissaries.

He took her to Thessalonica, where his friends testified falsely that the girl had promised to become his wife and accept their faith. Kirana proved to be a brave and steadfast Christian – she neither wanted to marry the rapist nor convert to Islam. Because of this, she was chained and thrown into prison. The commandant of the fortress, Ali Bey, allowed the janissaries to enter to Kirana’s prison and torture her as they wished. As we read from her left Biography:

"One beat her with a tree, – another – with a knife, a third – with kicks, a fourth – with fists, until they left her near dead…

And at night the locksmith of the prison hung her by the arms and grabbed any tree found and beat her mercilessly…".


sveta_Kiriana-Solunska

Thus, for a week, Kirana was severely tortured. On the seventh day (February 28, 1751) she died. And then a miracle happened –

28-02-crkvensveta-Kiranna-Solunska-ikona

"… a great light shone in the prison, came down from above from the roof like lightning, which surrounded the body of the martyr, spilled over the whole prison and illuminated it as if the whole sun had entered inside. It was then the fourth or fifth hour of the night (t . f. 10-11 o'clock at night)." In the morning, the Turks allowed the Christians to take the body of the martyr. They buried her outside the city, in the Christian cemetery there. Her clothes were divided among the faithful as sacred. Later, an unknown scribe compiled her life in Greek. The Church honors the memory of the holy martyr Kirana and commemorates her on February 28.

Biography source: Plamen Pavlov, Hristo Temelski Saints and spiritual leaders from Macedonia with minor modifications

Monitor service log is continously growing with Zabbix on Windows with batch userparameter script and trigger Alert if log is unchanged

Thursday, March 17th, 2022

monitor-if-log-file-is-growing-with-zabbix-zabbix-userparameter-script-howto

Recently we had an inteteresting Monitoring work task to achieve. We have an Application that is constantly simulating encrypted connections traffic to a remote side machine and sending specific data on TCP/IP ports.
Communiucation between App Server A -> App Server B should be continous and if all is working as expected App Server A messages output are logged in the Application log file on the machine which by the way Runs
Windows Server 2020.

Sometimes due to Network issues this constant reconnections from the Application S. A to the remote checked machine TCP/IP ports gets interrupted due to LAN issues or a burned Network Switch equipment, misconfiguration on the network due to some Network admin making stoopid stuff etc..

Thus it was important to Monitor somehow whether the log is growing or not and feed the output of whether Application log file is growing or it stuck to a Central Zabbix Server. 
To be able to better understand the task, lets divide the desired outcome in few parts on required:

1. Find The latest file inside a folder C:\Path-to-Service\Monitoring\Log\
2. Open the and check it is current logged records and log the time
3. Re-open file in a short while and check whether in few seconds new records are written
4. Report the status out to Zabbix
5. Make Zabbix Item / Trigger / Action in case if monitored file is not growing

In below article I'll briefly explain how Monitoring a Log on a Machine for growing was implemented using a pure good old WIN .BAT (.batch) script and Zabbix Userparameter key

 

1. Enable userparameter script for Local Zabbix-Agent on the Windows 10 Server Host


Edit Zabbix config file usually on Windows Zabbix installs file is named:

zabbix_agentd.win ]


Uncomment the following lines to enable userparameter support for zabbix-agentd:

 

# Include=c:\zabbix\zabbix_agentd.userparams.conf

Include=c:\zabbix\zabbix_agentd.conf.d\

# Include=c:\zabbix\zabbix_agentd.conf.d\*.conf


2. Create folders for userparameter script and for the userparameter.conf

Before creating userparameter you can to create the folder and grant permissions

Folder name under C:\Zabbix -> zabbix_agentd.conf.d

If you don't want to use Windows Explorer) but do it via cmd line:

C:\Users\LOGUser> mkdir \Zabbix\zabbix_agentd.conf\
C:\User\LOGUser> mkdir \Zabbix\zabbix_scripts\


3. Create Userparameter with some name file ( Userparameter-Monitor-Grow.conf )

In the directory C:\Zabbix\zabbix_agentd.conf.d you should create a config file like:
Userparameter-Monitor-Grow.conf and in it you should have a standard userparameter key and script so file content is:

UserParameter=service.check,C:\Zabbix\zabbix_scripts\GROW_LOG_MONITOR-USERPARAMETER.BAT


4. Create the Batch script that will read the latest file in the service log folder and will periodically check and report to zabbix that file is changing

notepad C:\Zabbix\zabbix_scripts\GROW_LOG_MONITOR-USERPARAMETER.BAT

REM "SCRIPT MONITOR IF FILE IS GROWING OR NOT"
@echo off

set work_dir=C:\Path-to-Service\Monitoring\Log\

set client=client Name

set YYYYMMDD=%DATE:~10,4%%DATE:~4,2%%DATE:~7,2%

set name=csv%YYYYMMDD%.csv

set mytime=%TIME:~0,8%

for %%I in (..) do set CurrDirName=%%~nxI

 

setlocal EnableDelayedExpansion

set "line1=findstr /R /N "^^" %work_dir%\output.csv | find /C ":""


for /f %%a in ('!line1!') do set number1=%%a

set "line2=findstr /R /N "^^" %work_dir%\%name% | find /C ":""


for /f %%a in ('!line2!') do set number2=%%a

 

IF  %number1% == %number2% (

echo %YYYYMMDD% %mytime% MAJOR the log is not incrementing for %client%

echo %YYYYMMDD% %mytime% MAJOR the log is not incrementing for %client% >> monitor-grow_err.log

) ELSE (

echo %YYYYMMDD% %mytime% NORMAL the log is incrementing for %client%

SETLOCAL DisableDelayedExpansion

del %work_dir%\output.csv

FOR /F "usebackq delims=" %%a in (`"findstr /n ^^ %work_dir%\%name%"`) do (

    set "var=%%a"

    SETLOCAL EnableDelayedExpansion

    set "var=!var:*:=!"

    echo(!var! >> %work_dir%\output.csv

    ENDLOCAL

)

)
 

 

To download GROW_LOG_MONITOR-USERPARAMETER.BAT click here.
The script needs to have configured the path to directory containing multiple logs produced by the Monitored Application.
As prior said it will, list the latest created file based on DATE timestamp in the folder will output a simple messages:

If the log file is being fed with data the script will output to output.csv messages continuously, either:

%%mytime%% NORMAL the log is incrementing for %%client%%

Or if the Monitored application log is not writting anything for a period it will start writting messages

%%mytime%%mytime MAJOR the log is not incrementing for %client%

The messages will also be sent in Zabbix.

Before saving the script make sure you modify the Full Path location to the Monitored file for growing, i.e.:

set work_dir=C:\Path-to-Service\Monitoring\Log\


5. Create The Zabbix Item

Set whatever service.check name you would like and a check interval to fetch the info from the userparameter (if you're dealing with very large log files produced by Monitored log of application, then 10 minutes might be too frequent, in most cases 10 minutes should be fine)
monitor-if-log-grows-windows-zabbix-item-service-check-screenshot
 

6. Create Zabbix Trigger


You will need a Trigger something similar to below:

Now considering that zabbix server receives correctly data from the client and the monitored log is growing you should in Zabbix:

%%mytime%% NORMAL the log is incrementing for %%client%%


7. Lastly create an Action to send Email Alert if log is not growing

How to configure Nautilus (Linux application like Windows Explorer) to work with standard Windows button + E On Linux GNOME en Mate

Monday, October 9th, 2017

how-to-configure-nautilus-linux-applicatoin-to-act-like-windows-explorer-make-windows-button-work-in-GNOME-and-Mate
As an ex-Windows user I'm still addicted to Windows User brainwashing as an ex-victim of Windows 95 / 98 and XP:), so I tend to love very much and its still hard for me to forget some major Key Binding (Windows Key Combinations).

On every new Desktop Linux I install, I have the habit to configure few great key combination shortcuts that makes my digital life much easier.
I use usually as a graphical environment GNOME and recently switched to MATE (GNOME 2 fork, cause GNOME 3 is totally messed up and unworthy to me), that's why this article is targetting this two Linux GUI envs, I'll be glad to hear in article comments for any other useful key bindings and how to configure similar key bindings for other Major Linux graphical environments (Cinnamon, KDE Plasma, XFCE, LXDE).

 

1. Configuring Lock Screen (Win button + L), Open Explorer(Win button + E), View Desktop (Win + D) in MATE graphic env

 

 

———  WINDOWS BUTTON, OFTEN USED KEY SHORTCUTS ———

Windows + E – Open new Windows File Explorer 

Windows + L – Lock Computer

Windows + M – To minimize All Windows

Windows + D – Show Desktop (similar to Windows +M though it doesn't switch to Desktop)

Win – + / – To Maginfy Text and Windows

Shift + Win + Left/Right Arrow – (In Windows if you have multiple monitors connected to the same computer lets say Right Monitor and Left, that combination switches between left monitor and right monitor)


——————————————————————–

 

The list goes on but I'm not used to all of them, I'll stop here and continue on with how to remake some of my favourite Windows keybindings in Gnu / Linux

Either run it from Menus:
 

System -> Settings -> Hardware -> Keyboard Shortcuts


Or run command

 

$ mate-keybinding-properties

 

howto-gnome-mate-remap-shortcut-keybinding-keys-mate-keybinding-properties


After rebinding the Windows: 
– Lock Screen and Open New Nautilus Explorer Window (Home folder) variable to be invoked with Windows button, the result
is as that:

howto-gnome-mate-remap-shortcut-keybinding-keys-mate-keybinding-properties
 
 

Scroll down Mate Keyboard shortcuts and you'll find

also how to configure Windows Button and D Key Combination, following 2 more screenshots showing how to do it note that MOD Key appears once you press Windows Keyboard Key + something (e.g. MATE recognizes MOD Key as Win Key):

Before the change to bind Win Key + D to work:

mate-how-to-make-desktop-view-open-with-standard-windows-button_and_d-combination-linux-debian

When configured Win Button + D looks like so:

mate-how-to-make-desktop-view-open-with-standard-windows-button_and_d-combination-linux-debian-1

2. Configuring Lock Screen (Win button + L), Open Explorer(Win button + E), View Desktop (Win + D) in GNOME

Usually in GNOME until > version 3.X.X (in older GNOME graphic environment access to KeyBinding Properties was done via:

 

System -> Preferences -> Keybord Shortcuts -> Add ->


In fallback gnome with Metacity (if installed along with GNOME Desktop 3.2.X environment to access Key Bindings):

d

System->Apps->Metacity->global_keybindings  

 

Also it is possible to remap keys via dconf-editor, I've written a small article earlier explaining how to remap Screenshotting buttons with dconf-editor but the example could be easily adapted, so you can edit almost everything.

Besides that you can use a command to run the keyboard configuration (in older GNOMEs) via:

 

linux:~$ gnome-keybinding-properties

 

Just for information for those who might know, many Key Binding interesting options are available via gnome-tweak-tool, so if you don't have it yet install it and give it a try:

 

linux:~# apt-get install –yes gnome-tweak-tool


As you can see, there are plenty of options to make Win (key) to act like Alt (key):

linux:~# gnome-tweak-tool
 

gnome-tweak-tool-make-win-key-to-behave-like-alt-key-howto 


After configuring the changes enjoy your WINDOWS Button + L, WINDOWS + E and WINDOWS + D WORKING AGAIN HOORAY !!! 🙂 
 

 

3. Most used shortcuts in Gnome and Nautilus 
 

Below are most used shortcuts thanks to LinuxQuestions Forum for providing them

Howdy! I thought that it would be useful to post a practical selection of shortcut keys for GNOME (the Desktop Environment) and Nautilus (the File Manager) and some information about customizing shortcut keys in Ubuntu. I wrote it especially for Ubuntu beginners, but I hope it will prove useful for all. 

 

2.1 GNOME/Nautilus shortcut keys – Very useful for the keyboard maniax like me :):
 

Ctrl-H: show hidden files

Ctrl-N: new window

Ctrl-Shift-N: create new folder

Alt-Home : jump to home folder

Alt-Enter : file / folder properties

F9 : toggle side-pane

Alt-F1 : launch applications menu

Alt-F2 : launch "run application" dialogue

Ctrl-Alt – Right/Left arrow : move to the next virtual desktop

Ctrl-Alt-Shift – Right/Left arrow : take current window to the next virtual desktop

Ctrl-Alt-D: minimize all windows, and gives focus to the desktop. 

Alt-Tab: switch between windows. When you use these shortcut keys, a list of windows that you can select is displayed. Release the keys to select a window. 

Ctrl-Alt-Tab: switch the focus between the panels and the desktop. When you use these shortcut keys, a list of items that you can select is displayed. Release the keys to select an item. 

Ctrl-Alt-L: lock the screen (tested only in Ubuntu) 

Ctrl-L: shortcut for opening locations-by default the path is the home folder*
/ : same as Ctrl-L but has the root (/) as default path* (shortcut found on here)
* both shortcuts can be used while you are on the desktop (no window active)

Ctrl-T : move to trash (in Nautilus)
Quite dangerous key combination because many of us are used to press these keys in order to open a new tab. Because we all delete items using the Delete key, I recommend to deactivate this shortcut key. To do that, go to System » Preferences » Appearance » Interface. Select Editable menu shortcut keys and close the dialog box. Click on the Edit menu in the File Browser. Click the Empty Trash item (it has Ctrl-T as the keyboard shortcut) Press the Delete key to get rid of the shortcut.
You can find all GNOME shortcut keys here

 

2.2 How to create a custom hotkey to launch whatever application you want in GNOME
 

As an example, we will set a lock-screen shortcut.


Open "gconf-editor" as the user as you're logged in in GNOME (typing gconf-editor in the terminal or "Run Application").
 

Go to apps > metacity > keybinding_commands


Here we have a list of twelve slots for commands.

 

Double click on e.g. "run_command_1" 

In Key Value Type in the name of the application or command you want to launch (e.g. gnome-screensaver-command –lock).

 

Go to apps -> Metacity -> global_keybindings 

Double click on e.g. "run_command_1" 
Change the key value to whatever key combination you like (e.g. <Ctrl><Alt>L).Press "Ok".

 

2.3.How to create/change GNOME shortcuts
 

 

Click on System -> Preferences -> Keyboard Shortcuts


Click the action in the list and press Enter. 
Press the new key or key combination you want to assign to the action. (To clear a shortcut, press the Backspace key)

 

Hope it helps, Enjoy Life .;)

Windows: command to show CPU info, PC Motherboard serial number and BIOS details

Wednesday, March 2nd, 2016

windows-command-to-show-motherboard-bios-and-cpu-serials-and-specific-info-with-wmic

Getting CPU information, RAM info and other various hardware specifics on Windows from the GUI interface is pretty trivial from Computer -> Properties
even more specifics could be obtained using third party Windows software such as CPU-Z

Perhaps there are plenty of many other ones to get and log info about hardware on PC or notebook system, but for Windwos sysadmins especially ones who are too much in love with command prompt way of behaving and ones who needs to automatizate server deployment processes with BATCH (.BAT)  scripts getting quickly info about hardware on freshly installed remote host Win server with no any additional hardware info tools, you'll be happy to know there are command line tools you can use to get extra hardware information on Windows PC / server:

The most popular tool available to present you with some basic hardware info is of course systeminfo

 

C:\> systeminfo

Host Name:                 REMHOST
OS Name:                   Microsoft Windows Server 2012 R2 Standard
OS Version:                6.3.9600 N/A Build 9600
OS Manufacturer:           Microsoft Corporation
OS Configuration:          Member Server
OS Build Type:             Multiprocessor Free
Registered Owner:          Registrar
Registered Organization:   Registrar
Product ID:                00XXX-X0000-00000-XX235
Original Install Date:     17/02/2016, 11:38:39
System Boot Time:          18/02/2016, 14:16:48
System Manufacturer:       VMware, Inc.
System Model:              VMware Virtual Platform
System Type:               x64-based PC
Processor(s):              1 Processor(s) Installed.
                           [01]: Intel64 Family 6 Model 45 Stepping 7 GenuineInt
el ~2600 Mhz
BIOS Version:              Phoenix Technologies LTD 6.00, 11/06/2014
Windows Directory:         C:\Windows
System Directory:          C:\Windows\system32
Boot Device:               \Device\HarddiskVolume1
System Locale:             de;German (Germany)
Input Locale:              de;German (Germany)
Time Zone:                 (UTC+01:00) Amsterdam, Berlin, Bern, Rome, Stockholm,
 Vienna
Total Physical Memory:     4,095 MB
Available Physical Memory: 2,395 MB
Virtual Memory: Max Size:  10,239 MB
Virtual Memory: Available: 8,681 MB
Virtual Memory: In Use:    1,558 MB
Page File Location(s):     C:\pagefile.sys
Domain:                    dom1.domain.com
Logon Server:              \\DOM
Hotfix(s):                 148 Hotfix(s) Installed.
                           [01]: KB2894852
                           [02]: KB2894856
                           [03]: KB2918614
                           [04]: KB2919355
…..


Now though systeminfo's hardware details and installed Windows KBXXXXX OS Hotfix patches are getting lists the command does not provide you with info about  system’s BIOS, thus to get this info you'll have to use also wmic (Windows Management Instrumentation Command).
 

 

So What Is WMIC?

WMIC extends WMI for operation from several command-line interfaces and through batch scripts. Before WMIC, you used WMI-based applications (such as SMS), the WMI Scripting API, or tools such as CIM Studio to manage WMI-enabled computers. Without a firm grasp on a programming language such as C++ or a scripting language such as VBScript and a basic understanding of the WMI namespace, do-it-yourself systems management with WMI was difficult. WMIC changes this situation by giving you a powerful, user-friendly interface to the WMI namespace.

WMIC is more intuitive than WMI, in large part because of aliases. Aliases take simple commands that you enter at the command line, then act upon the WMI namespace in a predefined way, such as constructing a complex WMI Query Language (WQL) command from a simple WMIC alias Get command. Thus, aliases act as friendly syntax intermediaries between you and the namespace. For example, when you run a simple WMIC command such as

Here is how to wmic to get PC Motherboard serial numbers, CPU and BIOS details:

 

C:\> wmic bios get name,serialnumber,version

 

Above will print  name if your BIOS, current version and it’s serial number if there is any.

If you need to get more info about the specific Motherboard installed on host:

 

C:\> wmic csproduct get name,identifyingnumber,uuid

 

This command will show motherboard modification and it’s UUID

If you want to quickly get what is Windows running hardware CPU clock speed
 

C:\> wmic cpu get name,CurrentClockSpeed,MaxClockSpeed

 

Also if you have turbo boost CPUs above command will help you find what’s the Max Clock Speed your system is capable of for the current hardware configuration.

If you do have dynamic clock speed running, then add this line, will refresh and monitor the Clock speed every 1 second.
 

C:\> wmic cpu get name,CurrentClockSpeed,MaxClockSpeed /every:1

Actually wmic is a great tool

Fix “FAIL – Application at context path /application-name could not be started” deployment error in Tomcat manager

Thursday, October 1st, 2015

tomcat-manager-FAIL-Application-at-context-path-application-name-could-not-be-started-fix-solution-error

While deploying an environment called "Interim" which is pretty much like a testing Java application deployed from a Java EAR (Enterprise Archive) file from within a Tomcat Manager GUI web interface after stopping the application and trying to start it, the developers come across the error:

 

FAIL – Application at context path /application-name could not be started


The error puzzled me for a while until I checked the catalina.out I've seen a number of thrown Java Eceptions errors like:

Okt 01, 2015 10:48:46 AM org.springframework.web.context.ContextLoader initWebApplicationContext

Schwerwiegend: Context initialization failed

org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'com.sun.xml.ws.transport.http.servlet.SpringBinding#2' defined in ServletContex

t resource [/WEB-INF/pp-server-beans.xml]: Cannot create inner bean ‘(inner bean)’ of type [org.jvnet.jax_ws_commons.spring.SpringService] while setting bean property

'service'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name '(inner bean)#33': FactoryBean threw exception on

 object creation; nested exception is java.lang.OutOfMemoryError: PermGen space

I've googled a bit about the error:

"FAIL – Application at context path /application-name could not be started"

and come across this Stackoverflow thread and followed suggested solution to fix web.xml tag closing error but it seems there was no such error in my case, I then also tried solution suggested by this thread (e.g. adding in logging.properties) file:
 

org.apache.catalina.core.ContainerBase.[Catalina].level = INFO
org.apache.catalina.core.ContainerBase.[Catalina].handlers = java.util.logging.ConsoleHandler

unfortunately this helped neither to solve the error when it is tried to be started from tomcat manager.

After asking for help a colleague Kostadin, he pointed me to take a closer look in the error (which is a clear indication) that the reserved space is not enough (see below err):
 

java.lang.OutOfMemoryError: PermGen space

And he pointed me then to Solution (which is to modify the present tomcat setenv.sh) settings which looked like this:

# Heap size settings

export JAVA_OPTS="-Xms2048M -Xmx2048M"

 

# SSCO test page parameter

export JAVA_OPTS="$JAVA_OPTS -DTS1A_TESTSEITE_CONFIG_PATH=test-myapplication.com"

# Default garbage collector settings

export JAVA_OPTS="$JAVA_OPTS -XX:MaxPermSize=128M"

 

# Aggressive garbage collector settings.

# Do not use! For testing purposes only!

#export JAVA_OPTS="$JAVA_OPTS -Xss128k -XX:ParallelGCThreads=20 -XX:+UseConcMarkSweepGC -XX:+UseParNewGC -XX:SurvivorRatio=8 -XX:TargetSurvivorRatio=90 -XX:MaxTenuringThreshold=31 -XX:+AggressiveOpts -XX:MaxPermSize=128M"

 

####### DO NOT CHANGE BELOW HERE #######

# Disable X11 usage

unset DISPLAY

export JAVA_OPTS="$JAVA_OPTS -Djava.awt.headless=true"

 

# Garbage collection log settings

export JAVA_OPTS="$JAVA_OPTS -verbose:gc -XX:+PrintGCTimeStamps -XX:+PrintGCDetails -Xloggc:/web/tomcat/current/logs/gc.log -XX:-TraceClassUnloading"

 

# Enable JMX console

export JAVA_OPTS="$JAVA_OPTS -Dcom.sun.management.jmxremote"

 

 

 

 

 

 

The solution is to to add following two options to export JAVA_OPTS (above options):

-XX:PermSize=512m -XX:MaxPermSize=512m


After modifications, my new line within setenv.sh looked like so:

 

JAVA_OPTS="-Xms2048M -Xmx2048M -XX:PermSize=512m -XX:MaxPermSize=512m"


Finally to make new JAVA_OPTS settings, I've restarted Tomcat with:

 

cd /web/tomcat/bin/
./shutdown.sh
sleep 5; ./startup.sh


And hooray it works fine thanks God! 🙂

PortQRY Native Windows command line Nmap like port scanner – Check status of remote host ports on Windows

Monday, June 30th, 2014

Windows_command_line_and_gui_port-scanner-portqry-like-nmap-check-status-of-remote-host-service-windows-xp-7-2000-2003-2008-server
Linux users know pretty well Nmap (network mapper) tool which is precious in making a quick server host security evaluation.
Nmap binary port is available for Windows too, however as nmap is port for its normal operation you have to install WinPcap (Packet Capture Library).
And more importantly it is good to mention if you need to do some remote port scanning from Windows host, there is Microsoft produced native tool called PortQry (Port Query).

PortQRY is a must have tool for the Windows Admin as it can help you troubleshoot multiple network issues.

windows-nmap-native-alternative-portqry-gui-ui-web-service-port-scan-screenshot
As of time of writting this post PortQRY is at version 2, PortQRY tool has also a GUI (UI) Version for those lazy to type in command line.

Port Query UI tool (portqueryui.exe) is a tool to query open ports on a machine. This tool makes use of command line version port query tool (portqry.exe). The UI provides the following functionalities:

   1. Following "Enter destination IP or FQDN to query:”, an edit box needs the user to specify the IP address or FDQN name of the destination to query port status.

   2. The end user is able to choose Query type:

        – Predefined services type. It groups ports into service, so that you can query multiple ports for a service by a single click. Service includes "Domains and Trusts", "DNS Queries", "NetBIOS     communication", "IPSEC", "Networking", "SQL Service", "WEB Service", "Exchange Server",          "Netmeeting", and other services.

You can check detail port and protocol info for each service category by opening Help -> Predefined Services…

PORTQRY is part of Windows Server 2003 Support Tools and can be added to any NT based Windows (XP, 2003, Vista, 7, 8)
 You can download portqry command line tool here or my mirrored portqry version command line port scanner here and PortQRY UI here.

PortQRY comes in PortQryV2.exe package which when run extracts 3 files: PortQry.exe program, EULA and readme file. Quickest way to make portqry globally accessible from win command prompt is to copy it to %SystemRoot% (The environment variable holding default location for Windows Installation directory).
It is good idea to add PortQRY to default PATH folder to make it accessible from command line globally.

PorQry has 3 modes of operation:

Command Line Mode, Interactive Mode and Local Mode

portqry-windows-native-security-port-network-scanner-nmap-equivalent-help-screenshot
 

Command Line Mode – is when it is invoked with parameters.

Interactive Mode is when it runs in interactive CLI console

portqry-windows-native-security-port-network-scanner-nmap-equivalent-interactive-mode-screenshot

portqry-windows-native-security-port-network-scanner-nmap-equivalent-interactive-mode-help-screenshot
and Local Mode is used whether information on local system ports is required.

portqry-windows-native-security-port-network-scanner-nmap-equivalent-local-mode-screenshot


Here are some examples on basic usage of portqry:
 

1. Check if remote server is running webserver is listening on (HTTPS protocol) TCP port 80

portqry -n servername -e 80
 

Querying target system called:

 www.pc-freak.net

Attempting to resolve name to IP address…


Name resolved to 83.228.93.76

querying…

TCP port 80 (http service): FILTERED

2. Check whether some common Samba sharing and DNS UDP ports are listening

portqry -n servername -p UDP -o 37,53,88,135
 

Querying target system called:

servername

Attempting to resolve name to IP address…


Name resolved to 74.125.21.100

querying…

UDP port 37 (time service): NOT LISTENING

UDP port 53 (domain service): NOT LISTENING

UDP port 88 (kerberos service): NOT LISTENING

UDP port 135 (epmap service): NOT LISTENING

3. Scan open ports in a port range – Check common services port range (port 1-1024)

portqry -n 192.168.1.20 -r 1:1024 | find ": LISTENING"

4. Logging network scan output to file

Portqry –n localhost –e 135 -l port135.txt
 

Querying target system called:

 localhost

Attempting to resolve name to IP address…


Name resolved to 127.0.0.1

querying…

TCP port 135 (epmap service): LISTENING

Using ephemeral source port
Querying Endpoint Mapper Database…
Server's response:

UUID: d95afe70-a6d5-4259-822e-2c84da1ddb0d
ncacn_ip_tcp:localhost[49152]

UUID: 2f5f6521-cb55-1059-b446-00df0bce31db Unimodem LRPC Endpoint
ncacn_np:localhost[PIPEwkssvc]

Total endpoints found: 38


5. Scanning UDP and TCP protocols port

PortQry -n www.pc-freak.net -e 25 -p both

 

Querying target system called:

 www.pc-freak.net

Attempting to resolve name to IP address…


Name resolved to 83.228.93.76

querying…

TCP port 53 (domain service): LISTENING

UDP port 53 (domain service): LISTENING or FILTERED

Sending DNS query to UDP port 53…

 

6. Checking remote server whether LDAP ports are listening

Portqry -remotehost.com -p tcp -e 389
Portqry -n remotehost.com -p tcp -e 636
Portqry -n remotehost.com -p both -e 3268
Portqry -n remotehost.com -p tcp -e 3269


7. Making SNMP community name requests

portqry -n host2 -cn !my community name! -e 161 -p udp


8. Initiating scan from pre-selected source port

A network socket request initiation is useful from certain port because, some remote services expect connection from certain ports, lets say you're connecting to mail server, you might want to set as a source port – port 25, to make remote server another SMTP is connecting.

portqry -n www.pc-freak.net -e 25 -sp 25


9. Scanning whether server ports required by Active Directories are opened

Common ports used in Windows hosts to communicate between each other to sustain Active Directory are:

88 (Kerberos)
135 (RPC)
389 (LDAP)
445 (CIFS)
3268 (Global Catalog)

portqry -n remote-host.com -o 88,135,389,445,3268 -p both

portqry has also a silent mode with the "-q" switch if you want to get only whether a port is LISTENING (opened).

On port scan it returns three major return codes (very useful for scripting purposes);

  • returncode 0 – if port / service is listening
  • returncode 1 – if service is not listening
  • returncode 2 – if service is listening or filtered

PortQry is very simple port scanner for win sysadms and is precious tool for basic network debugging (services)  on Windows farms, however it doesn't have the powerful cracker functionality, application / OS versioning etc. like Nmap.

 

Thomas Sunday – The day of Disbelievers

Monday, April 28th, 2014

Thomas-sunday-the-day-of-disbelieve-Thomas-reaching-to-Jesus-wounds

A week passed since we Christian celebrated Resurrection of Christ (Pascha). Each year on first Sunday after Easter in orthodox Church is celebrated the so called Thomas Sunday. So why is it called Thomas Sunday and why it is the day of disbelievers?
The root of this ancient Christian feast comes after commemoration of Christ desciple St. Thomas who disbelieved the testimony of ( 10 apostles ) and the Virgin Mary  that Jesus Christ is Risen from the Death.

The disbelieve of Thomas was logical and human cause even though Thomas was with the Apostles with Christ for 3 years, saw all Jesus miracles and shared the Secret Supper (Last Supper), and even knew in advance (heard by Jesus on Last supper) that Jesus will betrayed mocked, hanged on the Cross and Rise from the death on the third day, he disbelieved.

Thomas Sunday (Sundy of Thomas) is "the day of Disbelievers", because all are disbelievers in moments of their life not only those who believe God but all the humanity!  Even the most faithful Christian, be it a deacon, monk or priest has difficult moments in life where God's existence or providence for one's faith is seriously questioned.
The fallen nature of man is such that the initial belief in God given to man in Eden (Paradise garden) is broken, and only in Jesus's name through the Gift of Faith given by the Holy Spirit, believe in God is restored.

Thomas very much like unto everyone of us doubted the rumors of Christ resurrection and said he would only believe in Resurrected Christ only if he sees his hands nails print and put his fingers into Christ’s wounds to test he is not seeing a Ghost but Christ is alive in a body after his death.

Here is the Gospel reading re-telling the story in short:

“Then the same day at evening, being the first day of the week, when the doors were shut where the disciples were assembled for fear of the Jews, came Jesus and stood in the midst, and saith unto them, Peace be unto you.” (John 20:19)

“But Thomas, one of the twelve, called Didymus, was not with them when Jesus came. The other disciples therefore said unto him, We have seen the Lord. But he said unto them, Except I shall see in his hands the print of the nails, and put my finger into the print of the nails, and thrust my hand into his side, I will not believe.” (John 20:24-26)

And after eight days again his disciples were within, and Thomas with them: then came Jesus, the doors being shut, and stood in the midst, and said, Peace be unto you.
Then he said to Thomas, “Put your finger here; see my hands. Reach out your hand and put it into my side. Stop doubting and believe.”
Thomas said to him, “My Lord and my God!”
Then Jesus told him, “Because you have seen me, you have believed; blessed are those who have not seen and yet have believed.”
Jesus did many other miraculous signs in the presence of his disciples, which are not recorded in this book.
But these are written that you may believe that Jesus is the Christ, the Son of God, and that by believing you may have life in his name.” (John 20:31)

We Christians should be joyful for have not seen Christ in Flesh but have believed for we are blessed for his believe without seeing.

By same faith in God without seeing him even in old times the Jews were led by the Lord God in the desert have won wars by their believing without seeing God, prophets has prophecised, Simeon (The God receiver) hold The Savior (Christ) in his hands, by faith David won the battle with Goliath, by faith we understand the universe was formed at God’s command, by faith we know that the visible came out of the invisible.

o Kyrios mou kai o Theos mou (Greek) – My Lord and my God (Jn. 20:28) this declaration of faith clearly shows an unexpressable excitement of Thomas and his unexpectency to see Christ resurrected. Here it is interesting that here the son of God Jesus Christ is called by Thomas exactly how Jewish used to call God Yahweh (One and Only God) in the Old testament.

Today the evangical story is very accurate for our generation – a generation of disbelievers, even we who say we believe often doesn’t justify our believe with our deeds, we say we believe but we don’t keep God’s commandment “to love God and our neigbor like ourselves.” Often only difference between believers and disbelievers is on Sunday we believers visit Church and “play Christians”, but even but in daily life our deeds are same like unbelievers. Often many are disbelievers not because they reject God but because they never heard the Gospel or misheard it, also we disbelieve because we’re very much like st. Thomas, we often say “I will believe in God if I see him”, but even Thomas who saw God before the Crucifix and knew him disbelieved – a proof that often seing once could still leave space for doubt. The glorious event of Christ showing himself Alive to Thomas was made by Christ to establish the Church and strengthen faith of first Christians in resurrection. Nowadays there are plenty of people who question God’s existence saying that they will believe if they see but they’re not given to see the resurrected Christ because God knows that even if we see the Lord Jesus Christ resurrected we would try to rationally explain the phenomenon with holograms, modern technology or science.

Thomas Sunday is not only a day of Thomas disbelieve it is a day of disbelieve of all humanity. , St. Thomas should be an example even to all of us Christian disbelievers and non-believers that even if we disbelieve and doubt and strive to see God, He is powerful to come and appear Resurrected in His Glory to our souls.
Let us therefore have the Wisdom of the Holy Apostles and say together with them “Lord, Increase our faith.” Luke 17:5

Sofia Bulgaria one of the Most Ancient cities in Central Europe – the History of Europe

Friday, January 18th, 2013

Many Bulgarians might be striken to find out, today's territory of Bulgaria and on the balkans is in practice one of the ancient inhabitant territories in Europe. Sofia or Serdika, Sredets as the old name of Sofia used to be part of Roman Empire (Byzantine Empire), then of pre-Christian Bulgaria, after Christianization of Bulgaria part of the Bulgarian Empire and then after the fall of Bulgaria under turkish yoke part of Ottoman's Turkish Empire. Maybe surprisingly for many Western Europeans the city of Sofia, happened to be one of the ancient cities important for Christianity as it had a Bishop standing and a strong Christian community since 3rd century A.D. Even until today Sofia has kept its city design which is made in a Roman fashion. Hope this little video unusually made by British will shed up some light to people interested in Ancient Christian history. Enjoy 🙂

 

Sofia Bulgaria, one of the most ancient cities in Europe – the History of Europe

History of Belarus in 5 minutes – Learn a lot for Belarus in short time

Tuesday, October 30th, 2012

I've been recently interested in Belarusian History. I found few very interesting videos in youtube, so decided with people who want to learn more about Slavonic Culture. Belarus is a Slavonic culture and old Belarusian language dates back to Ancient Bulgarian traditions. Also Belarusian Ancient language includes a lot of Slavonic Ancient Bulgarian words. As a Bulgarian it is very interesting to me too the severe impact that our Great Bulgarian nation had on Slavonic Nations and Russians. Belarusians both lingually and culturely are very close to us Bulgarian. Orthodox Christian faith which later spread in Belarusian lands, has also been transferred from Bulgarian and Serbian lands to Belarus. After the pupils of Saint Cyril and Methodius, spread Slavonic alphabet in nowdays Romanian lands, Moldova and Belarus.
The first below video Belarus History in 5 minutes has a genuine video and musical arrangment. It was quite interesting to me, find out Belarussian people had a long known tradition in Musical Instruments and Folklore Music. Nowdays they produce also a great Gothic Music, just like most of celtic nations 🙂

History of Bulgarus in 5 minutes – Aristic short presentation lesson on Belarussian history


0:02
At first, there was nothing

 

0:03
now there’s a lot of everything

 

0:04
we have to thank God for that

 

0:06
He created our world in the freestyle genre

 

0:09
He said, "Budzma" (“So be it!”)

 

0:10
and Our Land appeared.

 

0:11
Ichthyosauri and other dragons…

 

0:13
in the beginning, we lived in the ocean

 

0:15
but then we left the bosom of the sea

 

0:17
and started to be called the Neuri.

 

0:19
From the earliest times

 

0:21
the Neuri could turn into wolves

 

0:23
that was a customary thing for them…

 

0:26
Žycien, Piarun, Dažboh, and Svaroh

 

0:28
our ancestors believed in heathen gods

 

0:30
but Christianity already knocked on the door.

 

0:34
Let’s know our roots! The Belarusians, the daring people!

 

0:38
In the year 862 of our era

 

0:41
the city of Polacak was mentioned for the first time

 

0:43
There, St. Safija Cathedral was build

 

0:45
(there’re only three such churches in the world)

 

0:47
Local Prince Usiaslau Caradziej

 

0:49
was a cool personage; Listen what I say!

 

0:51
St. Jefrasinnia lived in Polacak

 

0:53
the memory of her is cherished down the ages

 

0:56
The famous cross was made for her

 

0:58
(it wasn’t just super, it was marvelous)

 

1:00
but during WWII, it was lost

 

1:02
and now it’s our own grail

 

1:04
Let’s continue, let’s march ahead

 

1:07
The time of Grand Prince Mindouh came

 

1:09
and here we must remember that

 

1:11
Belarus was called Litva then

 

1:13
or rather – the Grand Principality of Litva

 

1:15
its coat of arms was Pahonia (pursuit)

 

1:16
it had a formidable army

 

1:17
Our capital Vilnia was founded by

 

1:19
Grand Prince Hiedymin

 

1:21
the legend says he had a dream about an iron wolf…

 

1:24
Wikipedia describes this event

 

1:26
Let’s know our roots!

 

1:28
The Belarusians, the daring people!

 

1:31
The year 1362

 

1:34
The sword is drawn; flags flutter in the wind…

 

1:36
In the Battle of Blue Waters

 

1:38
our army defeated three Khans of the Golden Horde

 

1:41
and the Grand Principality of Litva suddenly

 

1:43
became the largest country in Europe

 

1:45
Let’s continue, let’s march ahead.

 

1:47
Vitaut reigns in the Grand Principality

 

1:49
The Teutonic Order threatens us.

 

1:51
The Battle of Grunwald shows who’s right

 

1:53
Vitaut and Jahajla, King of Poland

 

1:55
junked the Crusaders like scrap metal

 

2:00
Francysk Skaryna was a tough guy

 

2:02
he went to study abroad

 

2:04
He was the first who printed the Bible

 

2:06
in the Old Belarusian language in Prague

 

2:08
Our warriors were tough men, too

 

2:11
they defeated the Moscow Army near Vorsa

 

2:13
in the year 1514

 

2:17
In the meantime, the Grand Principality of Litva

 

2:19
accepted its constitution – the Statute of the GPL 1588

 

2:21
In the Battle of Kircholm, we defeated the Swedish army

 

2:24
Apparently, you didn’t know this fact before.

 

2:26
Let’s know our roots!

 

2:28
In the city of Mahilou

 

2:30
7,000 invaders were killed in the fight

 

2:32
Who were these invaders? Well, these … from the East

 

2:34
representatives of the "brotherly" Russian nation

 

2:37
They were called Muscovites then.

 

2:38
And there’s already a new state

 

2:40
the Polish–Litvian Commonwealth

 

2:43
For some reason, it irritated all the neighbors

 

2:45
The three partitions of this Commonwealth

 

2:47
and we were divided between three states

 

2:49
The biggest part was occupied by Russia

 

2:51
It engendered discontent among the nobility

 

2:53
and Tadevus Kasciuska appears on the scene

 

2:56
It’s necessary to remember this name because

 

2:58
he was a great revolutionary

 

3:00
for liberty, equality and fraternity

 

3:02
he struggled even in the United States

 

3:04
but the Russian Tsar cast him into prison

 

3:06
Let’s know our roots!

 

3:10
During Napoleon’s war

 

3:13
the Belarusians fought with the Belarusians

 

3:15
and in 1863 there was a new rebellion

 

3:20
Kastus Kalinouski, a patriot of Belarus

 

3:24
and his peasant soldiers – "kasiniery"

 

3:25
struggled for independence

 

3:26
but he was caught and hanged in Vilnia

 

3:30
The world enters the 20th century

 

3:32
It’s necessary to revive our culture!

 

3:34
Bahusevic, Bahdanovic, Kupala and Kolas

 

3:36
Lastouski, Luckievic… Many people!

 

3:39
Dozens and dozens of outstanding names…

 

3:41
but the Red Revolution is approaching fast

 

3:45
Well, in the terror of the Revolution

 

3:47
a new state with a beautiful name was born

 

3:49
the Belarusian People’s Republic

 

3:51
We still celebrate the day it was proclaimed

 

3:54
But suddenly, out of the blue

 

3:56
another Republic was installed here

 

3:58
its name wasn’t romantic at all

 

4:00
Belarusian Soviet Socialist Republic.

 

4:02
The 1920s. We remember that time

 

4:04
Belarusianization is everywhere

 

4:06
Writers publish their excellent works

 

4:09
Viciebsk artists create their chefs-d’oeuvre…

 

4:11
This process was stopped

 

4:12
in the year 1937

 

4:14
the blood purge began.

 

4:15
After that, one more hell – WWII

 

4:20
There were invaders, there were partisans

 

4:21
the country was torn apart again…

 

4:24
The Belarusians fought with the Belarusians again

 

4:26
shedding each other’s blood

 

4:30
The war is over! No need to fight!

 

4:32
There’re cosmonauts flying in the sky

 

4:34
Maserau, it’s time for you to speak!

 

4:36
Piesniary, it’s time for you to sing!

 

4:39
Barys Kit, make your discoveries for NASA

 

4:41
and we keep living in our country

 

4:43
which name now is the Republic of Belarus

 

4:45
We’ve got our ensign and national emblem

 

4:47
we sing our songs and read our poems…

 

4:50
the year 1991…

 

4:51
Let’s know our roots!

 

4:54
The Belarusians, the daring people!

 

4:56
We stop here, but now it’s your time

 

4:58
All of you can write your own continuation…

 

5:00
Let’s know our roots!

 

5:02
The Belarusians, the daring people!

 

5:04
Let’s know our roots!

 

5:06
The Belarusians, the daring people!

 

5:09
Budzma viedac svoj rod!

 

5:11
Salony narod, Bielaruski narod!

 

History of Belarus Гісторыя Беларусі Historia Białorusi _ – 8 minutes video explaining in short Belarusian etymological roots

Ancient Musical Instruments of Belarus

Most importantly, nowdays Belarus still hold the light of Orthodox Christian faith, just like us Bulgarians. Spiritually Bulgaria and Belarus is united in our Orthodox Christian faith. This summer, I had the blessing many Belarusians in Pomorie Monastery (An Orthodox monastery located in the Black Sea sea coast (near Burgas) in Bulgaria). I've been amazed by the faith and spirituality Belarusians still hold even in this "dark times" of Christian faith decay and increased ungodliness.

History of Belarus (A 10 minutes short History of