Wednesday, August 13, 2014

Xubuntu 14.04 how to enable remote access.

1. Install vino vnc server:
sudo apt-get install vino-server
2. run vino preferences:
suod vino-preferences
3. configure preferences:


4. Update the firewall:
sudo ufw allow from any to any port 5600
5. Update the encryption requirements for remote access:
sudo apt-get install dconf-editor
dconf-editor
6. Disable require encryption:


7. Update the session manager via enabling Settings->Session and startup->Application autostart->Desktop Sharing:


8. Restart computer and try to connect vith any vnc client.

Thursday, July 10, 2014

How to set static IP and set my DNS in Ubuntu Server 14.04

If you try to edit /etc/resolv.conf as most information on internet suggest, your information will be overriden after reboot. To change DNS modify file:

sudo nano /etc/resolvconf/resolv.conf.d/base

Just add the same lines like in resolv.conf:

nameserver 8.8.8.8 #ip of your DNS server

then update resolv.conf:

sudo resolvconf -u

after that /etc/resolv.conf should contain your DNS ip.

To change ip address to static edit /etc/network/interfaces:

sudo nano /etc/network/interfaces

find and comment default dhcp entry. Next add lines to your config file like below:

# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).

# The loopback network interface
auto lo
iface lo inet loopback

# The primary network interface
auto eth0

# DHCP not needed
# iface eth0 inet dhcp
iface eth0 inet static
address 192.168.1.99
netmask 255.255.255.0
network 192.168.1.0
broadcast 192.168.1.255
gateway 192.168.254


then disable/enable network interface

sudo ifdown eth0 && sudo ifup eth0

Wednesday, July 9, 2014

How to grant root privileges in ubuntu for existing user

You need to add user to the "sudo" group. If you already created user "test" add user to the "sudo" group by issuing this command in terminal:

sudo usermod -a -G sudo test

check that ssh daemon is running:

sudo service ssh status

if firewall activated, add rule to allow ssh:

sudo ufw allow ssh

Wednesday, June 18, 2014

Exchange 2013. How to stop disclaimer from appearing in replies.

To stop disclaimers to appear in replies, just add some random generated string to disclaimer and add exception to that rule. That special string could be the same color as background, so it will be invisible in message body. You can add just some text from the disclaimer to exception condition, but if that text will be in message body then disclaimer will not be added to that message.

To add rule login to exchange admin center, select "mail flow" -> "rules", click "add"->"Apply disclaimers..."
Enter name and condition when disclaimer should be applied, select action "Append disclaimer...", enter text,and at the end add something like "<span style="font-size:10.0pt; color:#FFFFFF">2578AABHKJ213</span>" (there 2578AABHKJ213 random generated string and html tags make text size 10pt and text color is white, so it will be invisible on white background)
Next press "more options..." link, select "add exception if subject or body contains..." and add "2578AABHKJ213"

Thursday, April 10, 2014

Exchange 2013 unable to send email.

After we changed ISP our exchange server was unable to sent emails to some recipients. The error message it get from other servers was "421 Refused. Your reverse DNS entry does not resolve.". The problem was that ISP does not wrote PTR records in their DNS servers. When DNS records was ok. Problem was still there.
Short investigation show that we had 2 IP adresses on routers WAN interface, and default IP was not the same as dns record points to. The solution is to add NAT rule on the router so that source IP of the exchage server was changed to correct IP.

Exchange 2013 how to change banner message

get connectors list:

Get-Receiveconnector

set connector banner:

Set-Receiveconnector "connector name" -Banner "220 mail.domain.com"

check banner:

Get-Receiveconnector "connector name" | fl

delete banner:

Set-Receiveconnector "connector name" -Banner $null

Tuesday, February 11, 2014

Asterisk. Issue with IVR. DTMF not properly detected.

Asterisk routes all incoming calls, received through chan dongle, to IVR, where callers should press '1', '2' or '3'. Depends on selection made in IVR call is routed to different destination.
When call comes from mobile operator everything works fine, but when call received from landline(actually it was from alcatel pbx) it is impossible to choose destination in IVR.
Affter turning on DTMF logging and playing a little with IVR from landline, log looks like:

[Apr 18 07:56:28] DTMF[1787]: channel.c:4062 __ast_read: DTMF begin '1' received on Dongle/dongle0-0100000000
[Apr 18 07:56:28] DTMF[1787]: channel.c:4066 __ast_read: DTMF begin ignored '1' on Dongle/dongle0-0100000000
[Apr 18 07:56:30] DTMF[1787]: channel.c:4062 __ast_read: DTMF begin '2' received on Dongle/dongle0-0100000000
[Apr 18 07:56:30] DTMF[1787]: channel.c:4066 __ast_read: DTMF begin ignored '2' on Dongle/dongle0-0100000000
[Apr 18 07:56:30] DTMF[1787]: channel.c:4062 __ast_read: DTMF begin '3' received on Dongle/dongle0-0100000000
[Apr 18 07:56:30] DTMF[1787]: channel.c:4066 __ast_read: DTMF begin ignored '3' on Dongle/dongle0-0100000000


It means that asterisk detected DTMF, but duration is of DTMF is too short. To resolve this issue edit dongle.conf file. Find the section [dongleX] where 'X' dongle's number, which receives call, and add or edit parameter mindtmfduration=0. Restart asterisk and make test call. Log file should look like:

[Apr 18 10:35:02] DTMF[2014]: channel.c:4062 __ast_read: DTMF begin '1' received on Dongle/dongle0-0100000002
[Apr 18 10:35:02] DTMF[2014]: channel.c:4066 __ast_read: DTMF begin ignored '1' on Dongle/dongle0-0100000002
[Apr 18 10:35:02] DTMF[2014]: channel.c:3977 __ast_read: DTMF end '1' received on Dongle/dongle0-0100000002, duration 63 ms


It means that asterisk received DTMF code and accepted it(because it shows the duration in the log). After that increase mindtmfduration parameter until you find that asterisk do not accept DTMF signals like it was before. Then decrease duration to last working value.

Monday, January 13, 2014

Exchange 2013. Meeting invitations get stuck in a poison queue.

After meeting invitation arrives from external domain, and user accepts meeting. Meeting acceptance message some how crushes transport service and meeting initiator do not get confirmation about meeting acceptance.
The same scenario takes place when user trying to send meeting invitation from my organization to external. Transport service stops and then restarts.

Searching the web did not bring a lot of info, so I started to digging in event logs.
In the event log I found error 10003:

Event 10003, MSExchangeTransport
The transport process failed during message processing with the following call stack: System.ArgumentException: codePage is not detectable...

That probably happens because regional settings on server was set to "Lithuanian".
Check exchange configuration:

Get-RemoteDomain -Identity * | fl

CharacterSet and NonMimeCharacterSet on my server was set to iso-8859-13.
Change it to iso-8859-1("Western European ISO"):

Set-RemoteDomain -Identity * -CharacterSet iso-8859-1 -NonMimeCharacterSet iso-8859-1

after that users can send and accept invitations without any problems.