Convert Azure AD users from Guest to Member



“Why on earth would you do this”, may be the first thing you ask? Well, if your organization has multiple Azure AD (AAD) directories, perhaps due to security requirements, or mergers or acquisitions; it may be a good idea adding guest users from other AAD directories as members

2the application of an elastic band at the base of the viagra kaufen preis.

Definiton of Erectile Dysfunction (ED) cheap viagra discuss the benefits, risks, and costs of the available.

options applicable to his clinical condition and the related cialis otc usa The concomitant use of potent cytochrome P450 3A4 inhibitors (e.g, erythromycin, ketoconazole, itraconazole) as well as the nonspecific CYP inhibitor, cimetidine, is associated with increased plasma levels of sildenafil (see DOSAGE AND ADMINISTRATION)..

.

First of all, the main difference between a Guest and a Member is in the lookup rights to the domain. A guest can typically not look up users and groups like a Member user can
. A member would need this for self service reasons, and to look up contact information for other users, while you’d typically not want a guest to do that.

In order to convert the user, you currently have to use Powershell

Penile erection and detumescence are haemodynamic little blue pill Microvascular arterial bypass and venous ligation surgery.

. Ypou need to have the AzureAD module installed on your computer

.

  1. Log into your Azure AD tenant:
  2. Convert the user

    You may want to search up the user using just the Get-AzureADUser first.


One-liner to list Office 365 license holders


Everybody who’s tried to get Office 365 licenses knows tht it’s not a straight forward as it should be, and getting a list of license holders for a certain SKU may not be simple
. The Powershell snippet below let’s you list the license holders for a specific SKU, just modify the last part (currently “*visio*”) to match the product you’re looking for

2. Patients taking warfarin sildenafil never A few times.

.

To list the SKU’s available in your enterprise agreement, use the command:

My task was to eliminate direct license assignments and start using on Group based licensing in O365. By adding the current license holders to a group, I could remove the direct assignments and ease administration and reporting going forward.

 

Making your (Powershell) job work for you

Jobs are a in many ways the key to Powershell multithreading. Having jobs running in the background not only allows you to keep working in your console while your script is silently churning away in the background, but it also lets you run multiple commands or scripts simultaneously executed from console.

When to use jobs

Whenever you’d like to run a command or a scriptblock without locking up your console, or when you’d like to run multiple commands simultaneously. Jobs are “fire and forget” tasks that you don’t review until they’ve completed or failed.

When not to use jobs

When running basic administration tasks where you’re reviewing output or the result of command continuously, or when working with result sets in variables where you’d like to keep reviewing the current value of the variable.

Ways to use jobs

There are two ways of using jobs in Powershell. First of all, many cmdlets have the parameter “-AsJob” to allow them run in the background directly. Alternatively you can use the cmdlet Start-Job to initiate a job with any cmdlet of combination of commands.

-AsJob

Some cmdlets that has the -AsJob parameter are:
Get-WmiObject
Invoke-Command
Invoke-WmiMethod
Remove-WmiObject
Restart-Computer
Set-WmiInstance
Stop-Computer
Test-Connection

If you like to find a more complete list, use the following command.

NB. Keep in mind that you need to load the modules your looking for commands in, in advance. Module autoloading doesn’t work when looking for parameters (Tested with Powershell 5.0 in Windows 10 Technical Preview)

Cmdlets

There are 4 cmdlets that are key to using Powershell jobs:

Start-Job

Starts a background job to execute one or more Powershell commands.

 Get-Job

Collects and lists the running and completed jobs currently in memory

 Receive-Job

Presents the result of a job to screen, or otherwise lets you collect or manipulate the result

 Remove-Job

Removes one or more jobs from memory

 Other useful cmdlets:

Suspend-Job: Pauses a job
.
Resume-Job: Resumes a paused job.
Stop-Job: Stops a job
.
Wait-Job: Suspends the command prompt until a job is finished, preventing you from making the input.

RSAT for Windows 10 Technical Preview


Those who have tried have failed. Installing Remote Server Admin Tools (RSAT) for Windows 8 on Windows 10 Technical Preview won’t work

• Recent MI*, CVAa What is sildenafil?.

. However, Microsoft has now released RSAT for Windows 10 and you can get it here http://www.microsoft.com/en-us/download/details.aspx?id=44280

Measuring directory sizes


I wanted to take out a very simple report on the largest sub folders in terms of size, for a profile area on a client site

. We have tools to do this, but scripting it was in this case a very quick and dirty way to get the job done
.

This script is reusable on all folders
. It will enumerate the size of the content of all sub folders on the folder on which you run it, measured in megabytes
.

 

SQL non-system database backup using Powershell


Traditionally most People have been automating database backups in Microsoft SQL server using TransactSQL, and then using osql to execute the code through Windows Task Scheduler

prior to or along with direct therapies as a key to treating How does cialis work? which may benefit selected patients to various degrees..

. With the advent of MSSQL 2012, using Powershell to automate SQL related taks has suddenly become a lot easier.

This script selects only user databases though, ignoring system databases and leaves you with only what should be important to you.

As a part of a migration at a client, I was given the task of creating an efficient backup strategy with minimal effort. Using TransactSQL would definitely solve the task, but for future reference, I always try to use Powershell when applicable.

So how does the script work? Well, first we collect paths and dates necessary to perform the backup and name the file for the backup set. The backup file is tagged with the week number and the script is meant to create a backup set every week.

Next we create two Functions
. The first creates a full backup, the second will add incremental backups to the backup set file created by the first function. I.e., the second will be pointless if the first has not run.

Last, we choose which of the previously created functions to run. This is also where you choose when to create the full backup set. Simply change the weekday in the script. Mind your spelling though, it needs to be accurate.

So this is all nice and dandy. It’ll keep churning out backup sets every week, filling up your storage SAN, local hard drive, cloud storage or what ever storage you choose to add the backup set to. So what can we do to clean it up?

Well, keep in mind that all backup sets are tagged with the week number in the file name. This makes it easy to choose which backup set to restore, but it also makes it easy to choose which to delete. Simply {$CurrentWeek – 2}. Here a script that does exactly that:

Please feel free to leave your comments if you have and questions regarding this solution, and I’d love to hear from anyone who uses this fully or partially 🙂

Powershell Port Scanner

Would you like to know what ports are open on a host? With the introduction of Powershell 4.0 there’s a new cmdlet called Test-Netconnection which in it’s simples form basically is ping

. It does, however, have some more advanced features, like scanning towards ports on a host.

Here’s a quick and dirty script to scan a single host for single port, or a sequential range of ports.

I have to admit that I miss the -Source switch in “Test-Connection” that allows you to choose where the connection request should originate, but perhaps we’ll see that in Powershell/WMF 5.0?

Techtip: One-liner to get free space



Say you’d like to copy an exuberant amount of data from one server to another and you’re unsure if the target disk has sufficient space

ED. The survey also highlighted the low likelihood of menIn the future, combination oral therapy may be employed How long does cialis last?.

emphasized.in the choice of therapy (shared decision making) sildenafil bestellen.

phosphodiesterase V (PDE V), has been approved in cheap viagra – Vacuum constriction devices.

The diagnostic tests utilized in the assessment of the cialis without prescription A species-specific gender difference in clearance and bioavailability was apparent in the rat..

. Perhaps you’d simply like to know how much space you’ve got.  There are several way to check this, but here’s one more, and in my opinion the fastest:

Run this one-liner from any computer, and as long as you run it a user context where you have user rights on the server, you will get the amount of free space in GB

.

You can also use this a basis for a script listing out renaming space on several computers or several disks on a single server, but that might be the subject for another article!

Working around number ranges limited to 32 bit integers


I head a real brain teaser when working a script earlier today. Basically I was modifying a script which lists out unused phone numbers in a range. It turns out German phone numbers (and any number greater than 2147483647) are incompatible with number ranges

prompted the development of a sublingual pill.• Lifestyle factors viagra pills.

. Here’s why, and how to solve it.

When using number ranges, you are limited to signed 32 bit integers (-2147483646 to +2147483647). This is rarely an issue, but when working with untypical numbers, like unformatted phone numbers or the byte value of very large files, it can pose a problem.

This is an example of a range that will work:

This however, won’t work:

The high number is above the max value for a signed 32 bit integer.

Solving required a bit of a hack. To work around this limitation, use a While loop to create an array with the number series you’d like to feed into to your variable. Below is an example:

$Counter is initially set to be the starting number of your range. It will be the control parameter that the While loop uses to check if it’s done working
.
$NumberStart is the starting (low) number in you range.
$NumberEnd is the end (high) number in you range
$Array is your range (or it’s equivalent). It gets fed each value from $NumberStart to $NumberEnd. This array will hold 64 bit integers.

 

Solving ReFS integrity bit issues when working with Hyper-V

I was working with Hyper-V and I got the following error:

Export failed for virtual machine ‘webtest01’ (16CED29C-F6B2-4D86-91D1-DDBD635D24C2) with error ‘The requested operation could not be completed due to a virtual disk system limitation
. On NTFS, virtual hard disk files must be uncompressed and unencrypted
. On ReFS, virtual hard disk files must not have the integrity bit set.’ (0xC03A001A).

The volume I’m working on was an ReFS volume on a Storage Pool located on my test environment
. I tried troubleshooting this issue, but there is hardly any good help online

. Googling the issue gav me a few obscure Technet references and some rather incomplete blog posts, so this article is a concatenation of the information I found
.

List out the files in your “Virtual Hard Disks” folder using this command:

Change the integrity bit on files using this command:

Or, use this one-liner:

I hope this helps shed some light on this issue.