Backtrack:  
 
showing posts tagged with 'software'
edited by on May 27th 2015, at 15:47
A collegue ran into an issue with Microsoft Outlook (2010) and the AVG Outlook plugin: when attempting to open mails on a shared Exchange mailbox, the message body would be cleared from that e-mail. The message body would be deleted from Exchange itself as well, resulting in other users accessing the mailbox to also see empty message bodies. If a mail contained attachments, they would be left alone.

After a long search, the culprit seemed to be the AVG Outlook plugin. Upon opening an e-mail, the plugin would scan the e-mail, which somehow went wrong, resulting in clearing the message body (probably because it was marked as bad?). Because of the nature of the mailbox (it's a shared Exchange   ...
edited by on May 27th 2015, at 15:25

Preferred:

String x = JComboBox.getSelectedItem().toString();

or

String x = String.valueOf(JComboBox.getSelectedItem());

The second method protects against null values as well.

Avoid using casting:

String x = (String)JComboBox.getSelectedItem();

This would work fine if the item is indeed a string, but will fail if it can (also) be any other data type. To be safe, use either of the first two methods.

edited by on May 26th 2015, at 16:25
Some notes about my experience with the upgrade of a Trend Micro OfficeScan 10.6 to 11.0.

Check the version requirements before upgrading: Upgrade path to OfficeScan 11.0.

Basically, be sure to have the latest version of your current major version and service pack installed.

Upgrade considerations for OfficeSCan (OSCE) servers and clients/agents

Check the system and OS requirements, as they have changed since 10.6 and 11.0. When upgrading, it is also recommended to create a backup, in case something goes wrong during the upgrade.

Upgrading from a version prior to 10, you may have to workaround losing your defined scan methods. This is not required when performing an in-place upgrade fro  ...
edited by on May 26th 2015, at 16:17
Two methods of truncating the transaction logs for a database for SQL Server 2008 or newer:

Perform a backup to the nul device, essentially a "black hole":

BACKUP LOG [databaseName] TO DISK = 'nul:'

Temporarily set the recovery model to SIMPLE, then shrink the transaction log:

ALTER DATABASE databaseName SET RECOVERY SIMPLEDBCC SHRINKFILE('databaseName_log', 0, TRUNCATEONLY)ALTER DATABASE databaseName SET RECOVERY FULL

WARNING: truncating the transaction log without a backup may result in data loss in case of a database failure!

EDIT (26/05/2015):

You could attempt the backup/shrink routine without changing the recovery mode, but this will most likely onl  ...
edited by on May 26th 2015, at 14:17
You can move the tempdb of a SQL Server instance to another location using T-SQL, but this requires a little bit of downtime: setting a new location will only take effect after a restart of the SQL Server instance.

First, retrieve the tempdb's current location and logical name:

Use tempdbGOSELECT name,filename FROM sys.sysfilesGO

This should give you two entries: one for the actual database, and one for the transaction log of tempdb. Now that we have the location and logical name, we can change it:

ALTER DATABASE tempdb MODIFY FILE (NAME = tempdev, FILENAME = 'T:\newdir\tempdb.mdf');GOALTER DATABASE tempdb MODIFY FILE (NAME = templog, FILENAME = 'T:\newdir\templog.ldf');GO

Replace the p  ...
edited by on May 26th 2015, at 14:05

If, when attempting to start SQL Server instance, you get an error 1814, this means there's a problem with the tempdb database. Either it can't be created because the disk or volume is not accessible for writing (i.e. a security permission problem), or the volume on which the tempdb resides does not have enough space available. If the latter is the problem, you'll need at least 2 MB of free space for tempdb to be created.

edited by on May 22nd 2015, at 09:21

Cisco AnyConnect VPN client may fail on Windows 7 for no apparent reason with the following error:

Error
Unable to establish VPN

A possible reason may be that Internet Connection Sharing has been enabled on one or more network interfaces (e.g. used for making a hotspot out of your laptop). Try disabling ICS, then try connecting again.

edited by on May 21st 2015, at 16:30
After running complex queries that use the tempdb of a SQL Server instance, it may become necessary to shrink the database again. However, when running the shrink operation on the tempdb, it can result in the database not shrinking at all, even when the used space is minimal.

The reason for this is most likely that the clearance of the tempdb is still in cache and not flushed to disk. You need to flush the changes to disk first, after which you will be able to shrink the tempdb. Do note that flushing will most likely impact database performance, so use with caution. Also, the tempdb will not shrink beyond the initial size, configured in the file group.

DBCC FREESYSTEMCACHE('ALL')USE [tempd  ...
edited by on May 20th 2015, at 16:45
After configuring HA for a vSphere 5 cluster, you may encounter the following warning on each ESX host:

Configuration Issues
The number of vSphere HA heartbeat datastores for this host is 1, which is less than required: 2

vSphere 5 introduces datastore heartbeats in addition to network hearts, which allows to distinguish between a network-isolated host and a crashed host. In order for datastore heartbeats to work properly, vSphere requires at least 2 shared datastores available on every host in the cluster. If there's less than 2 shared datastores, datastore heartbeats will not function properly, resulting in the configuration issue message.

If you only have one shared datastore and wish   ...
edited by on May 20th 2015, at 16:18

You can retrieve a list of stored procedures in a SQL Server database through T-SQL by querying the built-in information_schema partition.

SELECT * 
FROM db_name.information_schema.routines 
WHERE routine_type = 'PROCEDURE'

Replace db_name with the name of the database you wish to retrieve the list of stored procedures. You can adjust the WHERE-clause even more to get a more narrow list.

You can also do this with the master database which will return all (system and non-system) stored procedures.

edited by on May 20th 2015, at 14:01
Windows Small Business Server 2003 and 2008 (SBS2003 and SBS2008) are still widely in use, but CALs for these are no longer available for purchase. So, what if you require more CALs but cannot get rid of your old SBS?

SBS 2008 and SBS 2011 work on a trust-based CAL count, so they do not need activation. You can simply purchase SBS 2011 Standard CALs and exercise your downgrade rights. Note that this cannot be done with SBS 2011 Premium CALs as they contain features that are not the same as in SBS2008 Premium.

Unfortunately, for SBS 2003, it's not that simple, as it uses online activation for CALs. In this case, you still have to buy SBS 2011 CALs, which are legally usable on your SBS 2003,  ...
edited by on May 20th 2015, at 13:16
Sometimes, when navigating in your local folders (in your user profile), it may seem to take forever to open a specific (local) folder, and the green loading bar at the top crawls forth at a very slow pace. If that is the case, try turning off folder optimization.

Windows 7 introduced a new feature called folder optimization, which is basically telling Windows what to do with the files inside a folder, such as generating thumbnails for pictures and videos, reading metadata from documents, reading media information on music, etc. Occassionally, this process can take a long time, and can really slow down Windows Explorer when attempting to browse such a folder.

If you stumble across such   ...
edited by on May 20th 2015, at 12:51

You can hide user accounts from the Windows Welcome (log on) screen through the registry. This works with Vista and all later versions.

  1. Start up regedit.
  2. Navigate to the key: HKEY_LOCAL_MACHINE\Software\Microsoft\WindowsNT\CurrentVersion\Winlogon
  3. Under Winlogon, create a new key called SpecialAccounts
  4. Under SpecialAccounts, create another key called UserList.
  5. Under UserList, create a DWORD value for each account:
    • Name: the full account name (including spaces)
    • Type: DWORD (32-bit)
    • Value:
      • 0: hides the account
      • 1: shows the account
edited by on May 20th 2015, at 12:33
To change the e-mail (relay) server for your on-premise N-Central server, you need to log in to N-Central at the product or system level. By default, this account is the same as you use to log on to the central server setup (you connect to it on port 10000 of your N-Central server). Its username is usually productadmin@n-able.com.

Once logged in, navigate to Administration > Mail Network Settings > SMTP Authentication.



Make changes on this page accordingly. If you don't use a relay server, N-Central will attempt to send e-mail using MX. Else, all e-mail will be forwarded to the relay server. You can also set up authentication if your relay server requires it.



Click Sav  ...
edited by on May 20th 2015, at 11:18

This is a Perl script I wrote and used for the migration of a linux DHCP server (running dhcpd to a Windows DHCP server. The script looks in the dhcpd.conf configuration file for fixed reservations and exports these to a CSV for processing and importing in another server.

Usage is simple, as it takes its input from STDIN and outputs to STDOUT.

cat /etc/dhcpd.conf | perl export-dhcpd-reservations.pl > output.csv

The script is very simple and can probably do with a lot of improvements, but it's a start for anyone willing to develop it further. It is licensed as GPLv3.

edited by on May 19th 2015, at 16:10

Probably MSSQL 101, but this is how to quickly retrieve the structure of a table:

EXEC sp_help tbl_name
GO

tbl_name is the name of the table.

edited by on May 19th 2015, at 16:07
When attempting to run an online integrity check, or a backup on a large database (i.e. large data files), you may run into this error:

Error: 5123, Severity: 16, State: 1.CREATE FILE encountered operating system error 665(failed to retrieve text for this error. Reason: 15105) while attempting to open or create the physical file 'D:\MSSQL\Data\db.mdf:MSSQL_DBCC9'.

Further investigation reveals that the error 665 is in fact: The requested operation could not be completed due to a file system limitation.

Backup and consistency (dbcc) check operations requires the creation of a database snapshot. These snapshots are created as sparse files, which only works on NTFS (not ReFS), but has some l  ...
edited by on May 13th 2015, at 14:34

If you accidentally have misplaced or forgotten your Bitlocker Recovery key, but still have access to the system (with an elevated account), you can retrieve the recovery key quite easily through the command line:

Open an elevated command prompt and type:

manage-bde -protectors -get C:

Replace C: with any drive that has Bitlocker enabled. Note that if it's not the system volume but some other drive that's encrypted, you need to unlock it first before you can retrieve the recovery key.

showing posts tagged with 'software'
 
 
« November 2024»
SunMonTueWedThuFriSat
     12
3456789
10111213141516
17181920212223
24252627282930
 
Links
 
Quote
« If the batteries of a TV remote run out, why do we press the buttons so much harder? »