+ Post New Thread
Results 1 to 12 of 12
Cloud Services Thread, Exchange Online (365) - Powershell Pipe Limit? in Technical; Hi, In Exchange Online Powershell is there some kind of limt on the number of pipes I can use? For ...
  1. #1

    FN-GM's Avatar
    Join Date
    Jun 2007
    Location
    UK
    Posts
    16,054
    Thank Post
    888
    Thanked 1,729 Times in 1,492 Posts
    Blog Entries
    12
    Rep Power
    454

    Exchange Online (365) - Powershell Pipe Limit?

    Hi,

    In Exchange Online Powershell is there some kind of limt on the number of pipes I can use?

    For example if I do this

    Code:
    get-mailbox | Set-CasMailbox -OwaMailboxPolicy "Student OWA Policy" -ActiveSyncEnabled $false -PopEnabled $false -ImapEnabled $false -MAPIEnabled $false
    That works fine and the desired is applied.

    If I do this

    Code:
    get-mailbox | Set-Mailbox -AddressBookPolicy " Student Address Book Policy"
    That also works fine and the desired is applied.

    But If I run this

    Code:
    get-mailbox | Set-CasMailbox -OwaMailboxPolicy "Student OWA Policy" -ActiveSyncEnabled $false -PopEnabled $false -ImapEnabled $false -MAPIEnabled $false | Set-Mailbox -AddressBookPolicy " Student Address Book Policy"
    I get no errors as if the command has completed but the address book policy ins't applied

    Why is it ignoring anything after the second pipe please?

    Thanks

  2. #2

    Domino's Avatar
    Join Date
    Oct 2006
    Location
    Bromley
    Posts
    4,177
    Thank Post
    217
    Thanked 1,291 Times in 801 Posts
    Blog Entries
    4
    Rep Power
    512
    Because the 'set-casmailbox' command doesn't return an output?

  3. #3


    Join Date
    May 2009
    Posts
    3,135
    Thank Post
    276
    Thanked 849 Times in 637 Posts
    Rep Power
    334
    What is the output from Set-CasMailbox?

  4. #4

    FN-GM's Avatar
    Join Date
    Jun 2007
    Location
    UK
    Posts
    16,054
    Thank Post
    888
    Thanked 1,729 Times in 1,492 Posts
    Blog Entries
    12
    Rep Power
    454
    What do you mean when you say the output please?

  5. #5

    Domino's Avatar
    Join Date
    Oct 2006
    Location
    Bromley
    Posts
    4,177
    Thank Post
    217
    Thanked 1,291 Times in 801 Posts
    Blog Entries
    4
    Rep Power
    512
    Well 'get-mailbox' gets all the mailboxes, and passes that to 'set-casmailbox'. the output from 'set-casmailbox' is passed to 'set-mailbox'.

  6. #6

    FN-GM's Avatar
    Join Date
    Jun 2007
    Location
    UK
    Posts
    16,054
    Thank Post
    888
    Thanked 1,729 Times in 1,492 Posts
    Blog Entries
    12
    Rep Power
    454
    So what do I do to fix it please?

  7. #7

    Domino's Avatar
    Join Date
    Oct 2006
    Location
    Bromley
    Posts
    4,177
    Thank Post
    217
    Thanked 1,291 Times in 801 Posts
    Blog Entries
    4
    Rep Power
    512
    Run

    get-mailbox | Set-CasMailbox -OwaMailboxPolicy "Student OWA Policy" -ActiveSyncEnabled $false -PopEnabled $false -ImapEnabled $false -MAPIEnabled $false

    then

    get-mailbox | Set-Mailbox -AddressBookPolicy " Student Address Book Policy"

  8. #8

    FN-GM's Avatar
    Join Date
    Jun 2007
    Location
    UK
    Posts
    16,054
    Thank Post
    888
    Thanked 1,729 Times in 1,492 Posts
    Blog Entries
    12
    Rep Power
    454
    Is there anyway to do it in all one command please?

  9. #9

    Domino's Avatar
    Join Date
    Oct 2006
    Location
    Bromley
    Posts
    4,177
    Thank Post
    217
    Thanked 1,291 Times in 801 Posts
    Blog Entries
    4
    Rep Power
    512
    or add " -PassThru " onto the first command

    get-mailbox | Set-CasMailbox -OwaMailboxPolicy "Student OWA Policy" -ActiveSyncEnabled $false -PopEnabled $false -ImapEnabled $false -MAPIEnabled $false -PassThru | Set-Mailbox -AddressBookPolicy " Student Address Book Policy"

    http://windowsitpro.com/powershell/q...ing-powershell

  10. Thanks to Domino from:

    FN-GM (30th June 2014)

  11. #10

    FN-GM's Avatar
    Join Date
    Jun 2007
    Location
    UK
    Posts
    16,054
    Thank Post
    888
    Thanked 1,729 Times in 1,492 Posts
    Blog Entries
    12
    Rep Power
    454
    Cheers

  12. #11

    FN-GM's Avatar
    Join Date
    Jun 2007
    Location
    UK
    Posts
    16,054
    Thank Post
    888
    Thanked 1,729 Times in 1,492 Posts
    Blog Entries
    12
    Rep Power
    454
    Just tried -PassThru like you did above and its an invalid parameter

  13. #12

    Domino's Avatar
    Join Date
    Oct 2006
    Location
    Bromley
    Posts
    4,177
    Thank Post
    217
    Thanked 1,291 Times in 801 Posts
    Blog Entries
    4
    Rep Power
    512
    Well you could script it with a foreach loop to run through one command, then the other? PowerShell Foreach Loop operator | Foreach-object cmdlet

SHARE:
+ Post New Thread

Similar Threads

  1. Office 365 Exchange Online now 50GB Mailbox per user!
    By EduTech in forum Cloud Services
    Replies: 50
    Last Post: 18th September 2013, 03:33 PM
  2. Office 365 Powershell command, not doing what I expect
    By mbedford in forum Cloud Services
    Replies: 3
    Last Post: 7th June 2013, 08:37 PM
  3. Exchange 2010 - Useful Powershell Commands
    By bodminman in forum Windows Server 2008
    Replies: 0
    Last Post: 10th November 2010, 09:34 AM
  4. exchange 2007 set mail size limit
    By RabbieBurns in forum Windows Server 2008 R2
    Replies: 1
    Last Post: 23rd March 2010, 10:01 PM
  5. Exchange - Message Larger than current limit
    By thegrassisgreener in forum Windows
    Replies: 2
    Last Post: 25th September 2007, 08:25 AM

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •