Tuesday, February 18, 2014

LibreOffice 4 not opening files from smb

Just a note to myself,

It's a temporary fix, or as many call it, a workaround.

There is a bug in LO that you're not able to open files on smb share. The LO just start (may show a splash screen), and closes with no error.

The workaround is simple, as provided by Maxim Monastirsky (comment #15):

Open the .desktop file (such as /usr/share/applications/libreoffice4.1-writer.desktop for LO Writer) and comment the following line:
For Nautilus users:
X-GIO-NoFuse=true

For Dolphin users:
Open the same file, and comment the following line:
X-KDE-Protocols=file,http,smb,ftp,webdav

It's working now like a charm.

Wednesday, February 5, 2014

Can't send mail from kontact using davmail

I moved to Arch Linux recently with KDE, and tried setting my organization email account on Kontact using davmail.
It's not my first time, and I just used this steps as usual:
http://osdir.com/ml/kde-pim/2011-07/msg00146.html

Everything was setup except I couldn't send email and received the following error:
Error : davmail.exchange.ews.EWSException: ErrorSendAsDenied The user account which was used to submit this request does not have the right to send mail on behalf of the specified sending account
After lot of investigation, I found out that somehow "davmail is not sending the right "From" address in new versions".
That's Ok, except I have an old davmail server, that wasn't updated for some months, and it worked before I moved to Arch.

So I tried to check the Kmail side, and after a lot of time, came up with this note in the documentation:

The way of sending messages configured here will be used for your default identity and for all other identities that do not have their own way of sending messages. You can use different ways of sending messages for different identities by selecting the Outgoing Account check box in the Advanced tab of the Identities page.
Kmail Identity Edit
Kmail Identity settings
Let's check my identity then! And I've found the culprit.
Go to Configure Kmail ->  Identities -> Choose your Identity -> Modify.
I had no email address set in my Identity, right after setting it up, the emails sent successfully!

Not sure why it happened, maybe some change in the newer version of Kmail. But that fixed it for me, and hope does the same for you!

Saturday, October 5, 2013

Deinterlacing and converting MTS video files

For my trip abroad I had a Sony video camera I borrowed from my friend. The camera was filming in AVCHD format, in 1080i format, an interlaced video.
After coming home, I was searching for the best way, to preserve quality, to deinterlace the video files and keep them that way. I have tried several ways, also tried converting with VLC only to find out that there is a bug. So I came up with the following article:
http://cweiske.de/tagebuch/deinterlacing-1080i.htm

The way is to just use the command line, with the ffmpeg convert option. However, it came up to me, that the sameq option is no longer available which is used by the publisher. So I decided to publish this post, with the fix to the command. You just need to replace the sameq option with qscale 0:
ffmpeg -i in.MTS -vf yadif=1 -acodec ac3 -ab 192k -vcodec mpeg4 -f mp4 -y -qscale 0 out.mp4
Replace in.MTS with the source file and out.mp4 with the output file name.

This far it resulted in the best deinterlaced video quality I could find.
You can download ffmpeg here:
http://www.ffmpeg.org/download.html

Monday, August 26, 2013

Key Update Tool throws an error

Note to self:
If Key Update Tool (A tool to update Win XP Serial Key) is giving you this error:
The product key could not be updated on your computer.  This may be due to technical difficulties or network connectivity issues.  Please contact Microsoft Support for additional assistance.
 Make sure you have turned off Trend Micro antivirus.*

*May apply to other antivirus software as well.

Tuesday, August 13, 2013

Outlook on Exchange using wrong certificate

 Many of us encountered this error:
The name on the security certificate is invalid or does not match the name of the site.
But this time, it was something different.
Not my image, but the exact error. (Source not found)
99% that it's not the solution you are looking for. But I will still fill the gap for the 1% that may encounter it.

I will explain every step I did until I found the problem. There are some solutions that I've tried that didn't work for me, but might for you, so you may try them.
*If you don't want to read it all, just jump directly to my solution down below.

The System:
SBS 2008 (server 2008 + exchange 2007)
*The solution may also apply for greater versions of exchange.

The problem:
As we began upgrading people to outlook 2010 there were errors popping about the certificate.
So the first thing I did was issuing a certificate from GoDaddy and installing it using the SBS console.
It didn't fix the problem.
The server is pretty old, and it wasn't me who installed it in the first place and it wasn't me who maintained it for several years, so I decided to go the manual way.

Thursday, April 18, 2013

Outlook 2003 hangs when replying / forwarding certain emails

I haven't posted here in a while.
Anyway, I had a user with a problem, when replying or forwarding certain messages outlook would just hang, and you would find a process "WINWORD.EXE" with 50% cpu in task manager.
So after some digging in google, I decided to read further some posts (instead of just looking at best answers) and I found this post:
http://www.office-outlook.com/outlook-forum/index.php/m/282024/

Thanks John Blessing or jb[3], whoever you are. Thought no one answered you, your solution actually worked.

I quote what you need to do:
Sounds to me like a problem with Word Automation.

This is a stab in the dark:

Start menu -> run
Type:
regsvr32 ole32.dll
[enter]

John Blessing
 
Thank you again!

Monday, February 4, 2013

Push emails (ActiveSync) suddenly not working on server 2003

Today a small business server 2003 was shut down unexpectedly (Simple electricity issue). After the server came up, the ActiveSync was no longer working. What I mean is that people who had their phones configured no longer received emails automatically by push. However the emails did sync, after going to the email app, and refreshing them.
So what's going on? Actually it's pretty simple for people that know where to look, unfortunately I forgot about the order of the things to check, and it took me a bit longer.
If you go to the Application log in Event Viewer, you will see the following error:
IP-based AUTD failed to initialize because the processing of notifications could not be setup.  Error code [0x80004005].  Verify that no other applications are currently bound to UDP port [2883], or try specifying a different port number.
Or this:
 IP-based AUTD failed to initialize.  Error code: [0x80004005].

So what's the solution?
Just restart the DNS Service. Everything was ok after that.

But, the problem may come back again. So here's the permanent solution, after reading more about that on this page, you may need to add the following ports as reserved in the registry:
  • 1645-1646 - Used by IAS
  • 1701-1701 - Used by L2TP
  • 1812-1813 - Used by IAS
  • 2883-2883 - Used by AUTD
  • 4500-4500 - Used by IPSEC
Add this to the following registry:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters\ReservedPorts
Now restart the server to make sure everything is fine.

Hope it helped somebody.

Tuesday, September 4, 2012

Office 365, PowerShell and passwords

Since, as I know, most of us are familiar with Office 365, and maybe even using it. But most of us never do things than what the Office 365 Management site gives us. But then comes this day when you are assigned to do the things we can't do with the management service, like it happened to me.
Today I was asked to set the user passwords to some of our customers to never expire. Quite simple task in Active Directory if you ask me, but that's not the case in Office 365. You have to do this in PowerShell.
So I'll brick this post in two: The first part will show you how to connect to Exchange online in Office 365 using PowerShell, and the second will show you how to set the passwords to never expire.
I also encourage any system administrators to get more familiar with PowerShell and at least get the basic idea behind it. It will greatly assist you in understanding the principles of today ways of administration.

Instead of letting you dig trough this page at microsoft (link), I'll tell you what you need.
First, install Microsoft Online Services Sign-in Assistant:
32-bit
64-bit

Second, Install the Microsoft Online Services Module for Windows PowerShell:
32-bit
64-bit

Now, find and open Microsoft Online Services Module for Windows PowerShell from the start menu.


Enter this command after:
$LiveCred = Get-Credential
Enter your Office 365 Admin credentials (full email address and password).


This command will create a new PowerShell parameter $LiveCred with the credentials you are going to connect with. After that enter this command:
$Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://ps.outlook.com/powershell/ -Credential $LiveCred -Authentication Basic -AllowRedirection
This will create a new parameter $Session with the connection parameters.  > 
  Now let's open a new session:
Import-PSSession $Session

And connect to Office 365:
Connect-MsolService -Credential $LiveCred

Finally we're ready to execute the commands to Office 365.

Warning! Be careful with what you type, the below cmdlet's can cause you a lot of trouble!

Let's see our issue with passwords:
Get-MSOLUser | Select UserPrincipalName, PasswordNeverExpires
 
You can see a table with the username and a PasswordNeverExpires state (I have blanked the usernames). Some of them are blank, and some of them are set to false. Both of them means that the password is set to expire. So let's change it to never expire.

You can either make it per user:
Set-MsolUser -UserPrincipalName -PasswordNeverExpires $true
Change to the user name (usually email address).
or all users:
Get-MSOLUser | Set-MsolUser -PasswordNeverExpires $true

change $true to $false if you want to set it to expire again:
One user -
Set-MsolUser -UserPrincipalName -PasswordNeverExpires $false
All users -
Get-MSOLUser | Set-MsolUser -PasswordNeverExpires $false

But we're not done yet!
Yes, we've made our changes, but we must not forget to close the session. As said on this page:
If you close the Windows PowerShell window without disconnecting from the server-side session, your connection will remain open for 15 minutes. Your account can only have three connections to the server-side session at one time.
Here's how we close our session:
Remove-PSSession $Session
$session is the parameter name we set when created the session.

Now we're done.
Hope it helped you guys!

Monday, September 3, 2012

Aboundex bot

It's my first post with some story that may help you. So enjoy!
In the last month or so, I have encountered a lot of bots (around a thousand) scraping a forum I'm admin in. After some digging, I've seen that the most of the bots come from 173.192.x.x segment.
I went to a "whois" site which suggested that the segment is part of softlayer data centers:
NetRange:       173.192.0.0 - 173.193.255.255
CIDR:           173.192.0.0/15
OriginAS:       AS36351
NetName:        SOFTLAYER-4-8
NetHandle:      NET-173-192-0-0-1
Parent:         NET-173-0-0-0-0
NetType:        Direct Allocation
Comment:        SoftLayer provides on-demand IT infrastructure, dedicated servers and cloud resources.
RegDate:        2009-07-21
Updated:        2012-03-09
Ref:            http://whois.arin.net/rest/net/NET-173-192-0-0-1
What the? My site is located in Israel, and it's in Hebrew, so there's no reason for them to scan my site.
But, after googling around I've found this:
The Aboundex Crawler is a bot from Aboundex Search, currently operating out of the Softlayer network with the IP Address 173.192.34.95.
Reports about the Aboundex crawler claim it ignores rules in robots.txt, and is a fast page scraper which may switch IP's when blocked from spidering pages.
According to this, the Aboundex Crawler bot ignores the robots.txt file. So why just not ban them?
Well, I think if some new search engine or whatever want to make a good reputation, then it must follow some simple rules, and of course one of them is the robots.txt. So maybe something is wrong with my site? Let's check out what the Aboundex site suggest.
The site doesn't seem to be working, as it says "under construction" when you try to search something, but there is an about page with this info (the only link on the site):
How do i stop Aboundexbot from indexing my website? If you have a concern about Aboundexbot, we hope you give us a chance to address it via the email below but if you need to block Aboundexbot, the robots.txt file will allow you to accomplish that goal.

To block Aboundexbot from your entire web site you add this to your robots.txt file:

User-agent: Aboundexbot
Disallow: /  
I guess it's a good thing to try it. What you think? I'll update later as I'll add it to the forums.

Hope you enjoyed :)

Wednesday, December 14, 2011

less than a week to go!!

I just remembered that I have a blog XD
BTW, it's now available by this link: blog.tahvok.org.

You know what people say about the army, that it's all bad, that you will gain nothing of it and that it's much better being a civilian... Well I can't say all that about myself, at the beginning I was like that, but now when it all ends, I just understand how much things I understood in life, because of the army, and how much I gained from it, that who knows how much time it would to gain as a civillian, I've met many people, and many of them will still be my friends after the army, and i've got so much privilege to do things, and none would dare to let me do as a civillian man.
But still, everything has an end. I just hope I'll do better as a civillian :)